diff options
author | sung-su.kim <sung-su.kim@samsung.com> | 2017-05-25 18:47:52 +0900 |
---|---|---|
committer | sung-su.kim <sung-su.kim@samsung.com> | 2017-06-09 09:54:44 +0900 |
commit | 74d9f3940562524cb04b323d2bb458eaa5bd36e6 (patch) | |
tree | 2faf6ca42ce09594ad79726e80375553c6a50883 /ElmSharp/ElmSharp | |
parent | 602c52c8279bfce8a1e835ae269a63ac1e3b802b (diff) | |
download | elm-sharp-74d9f3940562524cb04b323d2bb458eaa5bd36e6.tar.gz elm-sharp-74d9f3940562524cb04b323d2bb458eaa5bd36e6.tar.bz2 elm-sharp-74d9f3940562524cb04b323d2bb458eaa5bd36e6.zip |
Enhance Index widget
Change-Id: If719a2a20ed231dc7517eb5d3dbf2072c9cc5255
Diffstat (limited to 'ElmSharp/ElmSharp')
-rwxr-xr-x | ElmSharp/ElmSharp/Index.cs | 70 |
1 files changed, 69 insertions, 1 deletions
diff --git a/ElmSharp/ElmSharp/Index.cs b/ElmSharp/ElmSharp/Index.cs index e177968..f73ec7a 100755 --- a/ElmSharp/ElmSharp/Index.cs +++ b/ElmSharp/ElmSharp/Index.cs @@ -104,6 +104,53 @@ namespace ElmSharp } /// <summary> + /// Set a delay change time for index object. + /// delay time is 0.2 sec by default. + /// </summary> + public double Delay + { + get + { + return Interop.Elementary.elm_index_delay_change_time_get(RealHandle); + } + set + { + Interop.Elementary.elm_index_delay_change_time_set(RealHandle, value); + } + } + + /// <summary> + /// Gets or sets the items level for a given index widget. + /// </summary> + public int Level + { + get + { + return Interop.Elementary.elm_index_item_level_get(RealHandle); + } + set + { + Interop.Elementary.elm_index_item_level_set(RealHandle, value); + } + } + + /// <summary> + /// Control standard_priority group of index. + /// Priority group will be shown as many items as it can, and other group will be shown one character only. + /// </summary> + public int Priority + { + get + { + return Interop.Elementary.elm_index_standard_priority_get(RealHandle); + } + set + { + Interop.Elementary.elm_index_standard_priority_set(RealHandle, value); + } + } + + /// <summary> /// Gets the last selected item, for a given index widget. /// </summary> public IndexItem SelectedItem @@ -153,6 +200,19 @@ namespace ElmSharp } /// <summary> + /// Insert a new item into the index object after item after. + /// </summary> + /// <param name="label">the label which the item should be indexed</param> + /// <param name="after">The index item to insert after.</param> + /// <returns>A object to the IndexItem added or null, on errors</returns> + public IndexItem InsertAfter(string label, IndexItem after) + { + IndexItem item = new IndexItem(label); + item.Handle = Interop.Elementary.elm_index_item_insert_after(RealHandle, after, label, null, (IntPtr)item.Id); + return item; + } + + /// <summary> /// Flush the changes made to the index items so they work correctly. /// </summary> /// <param name="level">The index level (one of 0 or 1) where changes were made</param> @@ -161,6 +221,14 @@ namespace ElmSharp Interop.Elementary.elm_index_level_go(RealHandle, level); } + /// <summary> + /// Removes all items from a given index widget. + /// </summary> + public void Clear() + { + Interop.Elementary.elm_index_item_clear(RealHandle); + } + protected override IntPtr CreateHandle(EvasObject parent) { IntPtr handle = Interop.Elementary.elm_layout_add(parent.Handle); @@ -189,4 +257,4 @@ namespace ElmSharp _children.Remove((IndexItem)sender); } } -} +}
\ No newline at end of file |