2 * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
4 * Licensed under the Apache License, Version 2.0 (the License);
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an AS IS BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
18 using System.ComponentModel;
23 /// It inherits <see cref="GenItem"/>.
24 /// An instance to the gengrid item is added.
25 /// It contains the Update() method to update a gengrid item which is given.
27 /// <since_tizen> preview </since_tizen>
28 [Obsolete("This has been deprecated in API12")]
29 public class GenGridItem : GenItem
31 internal GenGridItem(object data, GenItemClass itemClass) : base(data, itemClass)
35 internal GenGridItem(object data, GenItemClass itemClass, EvasObject parent) : base(data, itemClass, parent)
40 /// Gets or sets whether a given gengrid item is selected.
41 /// If one gengrid item is selected, any other previously selected items get unselected in favor of this new one.
44 /// If true, it is selected.
45 /// If false, it is unselected.
47 /// <since_tizen> preview </since_tizen>
48 [Obsolete("This has been deprecated in API12")]
49 public override bool IsSelected
53 return Interop.Elementary.elm_gengrid_item_selected_get(Handle);
57 Interop.Elementary.elm_gengrid_item_selected_set(Handle, value);
62 /// Sets or gets the cursor to be shown when the mouse is over the gengrid item.
64 /// <since_tizen> preview </since_tizen>
65 [Obsolete("This has been deprecated in API12")]
66 [EditorBrowsable(EditorBrowsableState.Never)]
67 public override string Cursor
71 return Interop.Elementary.elm_gengrid_item_cursor_get(Handle);
75 if (!string.IsNullOrEmpty(value))
77 Interop.Elementary.elm_gengrid_item_cursor_set(Handle, value);
81 Interop.Elementary.elm_gengrid_item_cursor_unset(Handle);
87 /// Sets or gets the style for this item cursor.
89 /// <since_tizen> preview </since_tizen>
90 [Obsolete("This has been deprecated in API12")]
91 [EditorBrowsable(EditorBrowsableState.Never)]
92 public override string CursorStyle
96 return Interop.Elementary.elm_gengrid_item_cursor_style_get(Handle);
100 Interop.Elementary.elm_gengrid_item_cursor_style_set(Handle, value);
105 /// Sets or gets the cursor engine only usage for this item cursor.
107 /// <since_tizen> preview </since_tizen>
108 [Obsolete("This has been deprecated in API12")]
109 [EditorBrowsable(EditorBrowsableState.Never)]
110 public override bool IsUseEngineCursor
114 return Interop.Elementary.elm_gengrid_item_cursor_engine_only_get(Handle);
118 Interop.Elementary.elm_gengrid_item_cursor_engine_only_set(Handle, value);
123 /// Sets or gets, or sets the style of the given gengrid item's tooltip.
125 /// <since_tizen> preview </since_tizen>
126 [Obsolete("This has been deprecated in API12")]
127 public override string TooltipStyle
131 return Interop.Elementary.elm_gengrid_item_tooltip_style_get(Handle);
135 Interop.Elementary.elm_gengrid_item_tooltip_style_set(Handle, value);
140 /// Gets the gengrid item's select mode.
142 /// <since_tizen> preview </since_tizen>
143 [Obsolete("This has been deprecated in API12")]
144 public override GenItemSelectionMode SelectionMode
148 return (GenItemSelectionMode)Interop.Elementary.elm_gengrid_item_select_mode_get(Handle);
152 Interop.Elementary.elm_gengrid_item_select_mode_set(Handle, (Interop.Elementary.Elm_Object_Select_Mode)value);
157 /// Gets or sets the gengrid item's row position, relative to the whole gengrid's grid area.
159 /// <since_tizen> preview </since_tizen>
160 [Obsolete("This has been deprecated in API12")]
166 Interop.Elementary.elm_gengrid_item_pos_get(Handle, out row, out column);
172 /// Gets or sets the gengrid item's column position, relative to the whole gengrid's grid area.
174 /// <since_tizen> preview </since_tizen>
175 [Obsolete("This has been deprecated in API12")]
181 Interop.Elementary.elm_gengrid_item_pos_get(Handle, out row, out column);
187 /// Sets the text to be shown in the gengrid item.
189 /// <param name="tooltip">The text to set.</param>
190 /// <since_tizen> preview </since_tizen>
191 [Obsolete("This has been deprecated in API12")]
192 public override void SetTooltipText(string tooltip)
194 Interop.Elementary.elm_gengrid_item_tooltip_text_set(Handle, tooltip);
198 /// Unsets the tooltip from item.
200 /// <since_tizen> preview </since_tizen>
201 [Obsolete("This has been deprecated in API12")]
202 public override void UnsetTooltip()
204 Interop.Elementary.elm_gengrid_item_tooltip_unset(Handle);
208 /// Updates the content of a given gengrid item.
209 /// This updates an item by calling all the GenItem class functions again to get the content, text, and states.
210 /// Use this when the original item data has changed and you want the changes to reflect.
213 /// <see cref="GenGrid.UpdateRealizedItems"/> to update the contents of all the realized items.
215 /// <since_tizen> preview </since_tizen>
216 [Obsolete("This has been deprecated in API12")]
217 public override void Update()
219 Interop.Elementary.elm_gengrid_item_update(Handle);
223 /// Sets the content to be shown in the tooltip item.
225 /// <since_tizen> preview </since_tizen>
226 [Obsolete("This has been deprecated in API12")]
227 protected override void UpdateTooltipDelegate()
229 Interop.Elementary.elm_gengrid_item_tooltip_content_cb_set(Handle,
230 TooltipContentDelegate != null ? _tooltipCb : null,