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.Runtime.InteropServices;
20 internal static partial class Interop
22 internal static partial class Elementary
24 [DllImport(Libraries.Elementary)]
25 internal static extern void elm_object_item_part_content_set(IntPtr obj, string part, IntPtr content);
27 [DllImport(Libraries.Elementary)]
28 internal static extern IntPtr elm_object_item_part_content_unset(IntPtr obj, string part);
30 [DllImport(Libraries.Elementary)]
31 internal static extern void elm_object_item_part_content_set(IntPtr obj, IntPtr part, IntPtr content);
33 [DllImport(Libraries.Elementary, EntryPoint = "elm_object_item_part_text_get", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true, CharSet = CharSet.Ansi)]
34 internal static extern IntPtr _elm_object_item_part_text_get(IntPtr obj, string part);
36 internal static string elm_object_item_part_text_get(IntPtr obj, string part)
38 var text = _elm_object_item_part_text_get(obj, part);
39 return Marshal.PtrToStringAnsi(text);
42 [DllImport(Libraries.Elementary)]
43 internal static extern void elm_object_item_color_class_color_set(IntPtr it, string part, int r, int g, int b, int a);
45 [DllImport(Libraries.Elementary)]
46 internal static extern void elm_object_item_color_class_color_get(IntPtr obj, string part, out int r, out int g, out int b, out int a);
48 [DllImport(Libraries.Elementary)]
49 internal static extern void elm_object_item_color_class_del(IntPtr obj, string part);
51 [DllImport(Libraries.Elementary)]
52 internal static extern void elm_object_item_part_text_set(IntPtr obj, string part, string label);
54 [DllImport(Libraries.Elementary)]
55 internal static extern void elm_object_item_part_text_set(IntPtr obj, IntPtr part, string label);
57 [DllImport(Libraries.Elementary)]
58 internal static extern IntPtr elm_object_item_data_get(IntPtr it);
60 [DllImport(Libraries.Elementary)]
61 internal static extern void elm_object_item_data_set(IntPtr it, IntPtr data);
63 [DllImport(Libraries.Elementary)]
64 internal static extern void elm_object_item_del(IntPtr obj);
66 [DllImport(Libraries.Elementary)]
67 internal static extern void elm_object_item_del_cb_set(IntPtr obj, Interop.Evas.SmartCallback callback);
69 [DllImport(Libraries.Elementary)]
70 internal static extern void elm_object_item_disabled_set(IntPtr obj, bool disable);
72 [DllImport(Libraries.Elementary)]
73 internal static extern bool elm_object_item_disabled_get(IntPtr obj);
75 [DllImport(Libraries.Elementary)]
76 internal static extern IntPtr elm_object_item_part_content_get(IntPtr obj, string part);
78 [DllImport(Libraries.Elementary)]
79 internal static extern IntPtr elm_object_item_access_object_get(IntPtr obj);
81 [DllImport(Libraries.Elementary)]
82 internal static extern void elm_object_item_access_unregister(IntPtr obj);
84 [DllImport(Libraries.Elementary)]
85 internal static extern IntPtr elm_object_item_track(IntPtr obj);
87 [DllImport(Libraries.Elementary)]
88 internal static extern void elm_object_item_untrack(IntPtr obj);
90 [DllImport(Libraries.Elementary)]
91 internal static extern IntPtr elm_object_item_widget_get(IntPtr obj);
93 [DllImport(Libraries.Elementary)]
94 internal static extern void elm_object_item_signal_emit(IntPtr obj, string emission, string source);
96 [DllImport(Libraries.Elementary)]
97 internal static extern void elm_object_item_signal_callback_add(IntPtr obj, string emission, string source, Elm_Object_Item_Signal_Cb func, IntPtr data);
99 [DllImport(Libraries.Elementary)]
100 internal static extern IntPtr elm_object_item_signal_callback_del(IntPtr obj, string emission, string source, Elm_Object_Item_Signal_Cb func);
102 [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
103 internal delegate bool Elm_Object_Item_Signal_Cb(IntPtr data, IntPtr item, string emission, string source);
105 [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
106 internal delegate IntPtr Elm_Tooltip_Item_Content_Cb(IntPtr data, IntPtr obj, IntPtr tooltip, IntPtr item);
108 internal enum Elm_Object_Select_Mode
110 ELM_OBJECT_SELECT_MODE_DEFAULT,
111 ELM_OBJECT_SELECT_MODE_ALWAYS,
112 ELM_OBJECT_SELECT_MODE_NONE,
113 ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY