1 #pragma warning disable CS1591
3 using System.Runtime.InteropServices;
4 using System.Collections.Generic;
6 using System.Threading;
7 using System.ComponentModel;
12 /// <summary>Tab_Page internal part class</summary>
13 [Efl.Ui.TabPagePartTab.NativeMethods]
14 public class TabPagePartTab : Efl.Ui.LayoutPart, Efl.Eo.IWrapper,Efl.IText
16 ///<summary>Pointer to the native class description.</summary>
17 public override System.IntPtr NativeClass
21 if (((object)this).GetType() == typeof(TabPagePartTab))
23 return GetEflClassStatic();
27 return Efl.Eo.ClassRegister.klassFromType[((object)this).GetType()];
32 [System.Runtime.InteropServices.DllImport(efl.Libs.Elementary)] internal static extern System.IntPtr
33 efl_ui_tab_page_part_tab_class_get();
34 /// <summary>Initializes a new instance of the <see cref="TabPagePartTab"/> class.</summary>
35 /// <param name="parent">Parent instance.</param>
36 public TabPagePartTab(Efl.Object parent= null
37 ) : base(efl_ui_tab_page_part_tab_class_get(), typeof(TabPagePartTab), parent)
39 FinishInstantiation();
42 /// <summary>Initializes a new instance of the <see cref="TabPagePartTab"/> class.
43 /// Internal usage: Constructs an instance from a native pointer. This is used when interacting with C code and should not be used directly.</summary>
44 /// <param name="raw">The native pointer to be wrapped.</param>
45 protected TabPagePartTab(System.IntPtr raw) : base(raw)
49 /// <summary>Initializes a new instance of the <see cref="TabPagePartTab"/> class.
50 /// Internal usage: Constructor to forward the wrapper initialization to the root class that interfaces with native code. Should not be used directly.</summary>
51 /// <param name="baseKlass">The pointer to the base native Eo class.</param>
52 /// <param name="managedType">The managed type of the public constructor that originated this call.</param>
53 /// <param name="parent">The Efl.Object parent of this instance.</param>
54 protected TabPagePartTab(IntPtr baseKlass, System.Type managedType, Efl.Object parent) : base(baseKlass, managedType, parent)
58 /// <summary>Verifies if the given object is equal to this one.</summary>
59 /// <param name="instance">The object to compare to.</param>
60 /// <returns>True if both objects point to the same native object.</returns>
61 public override bool Equals(object instance)
63 var other = instance as Efl.Object;
68 return this.NativeHandle == other.NativeHandle;
71 /// <summary>Gets the hash code for this object based on the native pointer it points to.</summary>
72 /// <returns>The value of the pointer, to be used as the hash code of this object.</returns>
73 public override int GetHashCode()
75 return this.NativeHandle.ToInt32();
78 /// <summary>Turns the native pointer into a string representation.</summary>
79 /// <returns>A string with the type and the native pointer for this object.</returns>
80 public override String ToString()
82 return $"{this.GetType().Name}@[{this.NativeHandle.ToInt32():x}]";
85 virtual public System.String GetIcon() {
86 var _ret_var = Efl.Ui.TabPagePartTab.NativeMethods.efl_ui_tab_page_part_tab_icon_get_ptr.Value.Delegate((inherited ? Efl.Eo.Globals.efl_super(this.NativeHandle, this.NativeClass) : this.NativeHandle));
87 Eina.Error.RaiseIfUnhandledException();
90 virtual public void SetIcon(System.String path) {
91 Efl.Ui.TabPagePartTab.NativeMethods.efl_ui_tab_page_part_tab_icon_set_ptr.Value.Delegate((inherited ? Efl.Eo.Globals.efl_super(this.NativeHandle, this.NativeClass) : this.NativeHandle),path);
92 Eina.Error.RaiseIfUnhandledException();
94 /// <summary>Retrieves the text string currently being displayed by the given text object.
95 /// Do not free() the return value.
97 /// See also <see cref="Efl.IText.GetText"/>.
98 /// (Since EFL 1.22)</summary>
99 /// <returns>Text string to display on it.</returns>
100 virtual public System.String GetText() {
101 var _ret_var = Efl.ITextConcrete.NativeMethods.efl_text_get_ptr.Value.Delegate((inherited ? Efl.Eo.Globals.efl_super(this.NativeHandle, this.NativeClass) : this.NativeHandle));
102 Eina.Error.RaiseIfUnhandledException();
105 /// <summary>Sets the text string to be displayed by the given text object.
106 /// See also <see cref="Efl.IText.GetText"/>.
107 /// (Since EFL 1.22)</summary>
108 /// <param name="text">Text string to display on it.</param>
109 virtual public void SetText(System.String text) {
110 Efl.ITextConcrete.NativeMethods.efl_text_set_ptr.Value.Delegate((inherited ? Efl.Eo.Globals.efl_super(this.NativeHandle, this.NativeClass) : this.NativeHandle),text);
111 Eina.Error.RaiseIfUnhandledException();
113 public System.String Icon {
114 get { return GetIcon(); }
115 set { SetIcon(value); }
117 private static IntPtr GetEflClassStatic()
119 return Efl.Ui.TabPagePartTab.efl_ui_tab_page_part_tab_class_get();
121 /// <summary>Wrapper for native methods and virtual method delegates.
122 /// For internal use by generated code only.</summary>
123 public new class NativeMethods : Efl.Ui.LayoutPart.NativeMethods
125 private static Efl.Eo.NativeModule Module = new Efl.Eo.NativeModule( efl.Libs.Elementary);
126 /// <summary>Gets the list of Eo operations to override.</summary>
127 /// <returns>The list of Eo operations to be overload.</returns>
128 public override System.Collections.Generic.List<Efl_Op_Description> GetEoOps(System.Type type)
130 var descs = new System.Collections.Generic.List<Efl_Op_Description>();
131 var methods = Efl.Eo.Globals.GetUserMethods(type);
133 if (efl_ui_tab_page_part_tab_icon_get_static_delegate == null)
135 efl_ui_tab_page_part_tab_icon_get_static_delegate = new efl_ui_tab_page_part_tab_icon_get_delegate(icon_get);
138 if (methods.FirstOrDefault(m => m.Name == "GetIcon") != null)
140 descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_ui_tab_page_part_tab_icon_get"), func = Marshal.GetFunctionPointerForDelegate(efl_ui_tab_page_part_tab_icon_get_static_delegate) });
143 if (efl_ui_tab_page_part_tab_icon_set_static_delegate == null)
145 efl_ui_tab_page_part_tab_icon_set_static_delegate = new efl_ui_tab_page_part_tab_icon_set_delegate(icon_set);
148 if (methods.FirstOrDefault(m => m.Name == "SetIcon") != null)
150 descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_ui_tab_page_part_tab_icon_set"), func = Marshal.GetFunctionPointerForDelegate(efl_ui_tab_page_part_tab_icon_set_static_delegate) });
153 if (efl_text_get_static_delegate == null)
155 efl_text_get_static_delegate = new efl_text_get_delegate(text_get);
158 if (methods.FirstOrDefault(m => m.Name == "GetText") != null)
160 descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_text_get"), func = Marshal.GetFunctionPointerForDelegate(efl_text_get_static_delegate) });
163 if (efl_text_set_static_delegate == null)
165 efl_text_set_static_delegate = new efl_text_set_delegate(text_set);
168 if (methods.FirstOrDefault(m => m.Name == "SetText") != null)
170 descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_text_set"), func = Marshal.GetFunctionPointerForDelegate(efl_text_set_static_delegate) });
173 descs.AddRange(base.GetEoOps(type));
176 /// <summary>Returns the Eo class for the native methods of this class.</summary>
177 /// <returns>The native class pointer.</returns>
178 public override IntPtr GetEflClass()
180 return Efl.Ui.TabPagePartTab.efl_ui_tab_page_part_tab_class_get();
183 #pragma warning disable CA1707, SA1300, SA1600
185 [return: MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))]
186 private delegate System.String efl_ui_tab_page_part_tab_icon_get_delegate(System.IntPtr obj, System.IntPtr pd);
188 [return: MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))]
189 public delegate System.String efl_ui_tab_page_part_tab_icon_get_api_delegate(System.IntPtr obj);
191 public static Efl.Eo.FunctionWrapper<efl_ui_tab_page_part_tab_icon_get_api_delegate> efl_ui_tab_page_part_tab_icon_get_ptr = new Efl.Eo.FunctionWrapper<efl_ui_tab_page_part_tab_icon_get_api_delegate>(Module, "efl_ui_tab_page_part_tab_icon_get");
193 private static System.String icon_get(System.IntPtr obj, System.IntPtr pd)
195 Eina.Log.Debug("function efl_ui_tab_page_part_tab_icon_get was called");
196 Efl.Eo.IWrapper wrapper = Efl.Eo.Globals.PrivateDataGet(pd);
199 System.String _ret_var = default(System.String);
202 _ret_var = ((TabPagePartTab)wrapper).GetIcon();
206 Eina.Log.Warning($"Callback error: {e.ToString()}");
207 Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
215 return efl_ui_tab_page_part_tab_icon_get_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)));
219 private static efl_ui_tab_page_part_tab_icon_get_delegate efl_ui_tab_page_part_tab_icon_get_static_delegate;
222 private delegate void efl_ui_tab_page_part_tab_icon_set_delegate(System.IntPtr obj, System.IntPtr pd, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))] System.String path);
225 public delegate void efl_ui_tab_page_part_tab_icon_set_api_delegate(System.IntPtr obj, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))] System.String path);
227 public static Efl.Eo.FunctionWrapper<efl_ui_tab_page_part_tab_icon_set_api_delegate> efl_ui_tab_page_part_tab_icon_set_ptr = new Efl.Eo.FunctionWrapper<efl_ui_tab_page_part_tab_icon_set_api_delegate>(Module, "efl_ui_tab_page_part_tab_icon_set");
229 private static void icon_set(System.IntPtr obj, System.IntPtr pd, System.String path)
231 Eina.Log.Debug("function efl_ui_tab_page_part_tab_icon_set was called");
232 Efl.Eo.IWrapper wrapper = Efl.Eo.Globals.PrivateDataGet(pd);
238 ((TabPagePartTab)wrapper).SetIcon(path);
242 Eina.Log.Warning($"Callback error: {e.ToString()}");
243 Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
250 efl_ui_tab_page_part_tab_icon_set_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)), path);
254 private static efl_ui_tab_page_part_tab_icon_set_delegate efl_ui_tab_page_part_tab_icon_set_static_delegate;
256 [return: MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))]
257 private delegate System.String efl_text_get_delegate(System.IntPtr obj, System.IntPtr pd);
259 [return: MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))]
260 public delegate System.String efl_text_get_api_delegate(System.IntPtr obj);
262 public static Efl.Eo.FunctionWrapper<efl_text_get_api_delegate> efl_text_get_ptr = new Efl.Eo.FunctionWrapper<efl_text_get_api_delegate>(Module, "efl_text_get");
264 private static System.String text_get(System.IntPtr obj, System.IntPtr pd)
266 Eina.Log.Debug("function efl_text_get was called");
267 Efl.Eo.IWrapper wrapper = Efl.Eo.Globals.PrivateDataGet(pd);
270 System.String _ret_var = default(System.String);
273 _ret_var = ((TabPagePartTab)wrapper).GetText();
277 Eina.Log.Warning($"Callback error: {e.ToString()}");
278 Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
286 return efl_text_get_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)));
290 private static efl_text_get_delegate efl_text_get_static_delegate;
293 private delegate void efl_text_set_delegate(System.IntPtr obj, System.IntPtr pd, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))] System.String text);
296 public delegate void efl_text_set_api_delegate(System.IntPtr obj, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))] System.String text);
298 public static Efl.Eo.FunctionWrapper<efl_text_set_api_delegate> efl_text_set_ptr = new Efl.Eo.FunctionWrapper<efl_text_set_api_delegate>(Module, "efl_text_set");
300 private static void text_set(System.IntPtr obj, System.IntPtr pd, System.String text)
302 Eina.Log.Debug("function efl_text_set was called");
303 Efl.Eo.IWrapper wrapper = Efl.Eo.Globals.PrivateDataGet(pd);
309 ((TabPagePartTab)wrapper).SetText(text);
313 Eina.Log.Warning($"Callback error: {e.ToString()}");
314 Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
321 efl_text_set_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)), text);
325 private static efl_text_set_delegate efl_text_set_static_delegate;
327 #pragma warning restore CA1707, SA1300, SA1600