[NUI] TCSACR-226 code change (#1032)
[platform/core/csapi/tizenfx.git] / internals / src / EflSharp / EflSharp / efl / efl_ui_layout_factory.eo.cs
1 #define EFL_BETA
2 #pragma warning disable CS1591
3 using System;
4 using System.Runtime.InteropServices;
5 using System.Collections.Generic;
6 using System.Linq;
7 using System.Threading;
8 using System.ComponentModel;
9 namespace Efl {
10
11 namespace Ui {
12
13 /// <summary>Efl Ui Layout Factory class</summary>
14 /// <remarks>This is a <b>BETA</b> class. It can be modified or removed in the future. Do not use it for product development.</remarks>
15 [Efl.Ui.LayoutFactory.NativeMethods]
16 [Efl.Eo.BindingEntity]
17 public class LayoutFactory : Efl.Ui.CachingFactory
18 {
19     /// <summary>Pointer to the native class description.</summary>
20     public override System.IntPtr NativeClass
21     {
22         get
23         {
24             if (((object)this).GetType() == typeof(LayoutFactory))
25             {
26                 return GetEflClassStatic();
27             }
28             else
29             {
30                 return Efl.Eo.ClassRegister.klassFromType[((object)this).GetType()];
31             }
32         }
33     }
34
35     [System.Runtime.InteropServices.DllImport(efl.Libs.Elementary)] internal static extern System.IntPtr
36         efl_ui_layout_factory_class_get();
37     /// <summary>Initializes a new instance of the <see cref="LayoutFactory"/> class.</summary>
38     /// <param name="parent">Parent instance.</param>
39     /// <param name="itemClass">Define the class of the item returned by this factory. See <see cref="Efl.Ui.WidgetFactory.SetItemClass" /></param>
40     public LayoutFactory(Efl.Object parent
41             , Type itemClass = null) : base(efl_ui_layout_factory_class_get(), parent)
42     {
43         if (Efl.Eo.Globals.ParamHelperCheck(itemClass))
44         {
45             SetItemClass(Efl.Eo.Globals.GetParamHelper(itemClass));
46         }
47
48         FinishInstantiation();
49     }
50
51     /// <summary>Subclasses should override this constructor if they are expected to be instantiated from native code.
52     /// Do not call this constructor directly.</summary>
53     /// <param name="ch">Tag struct storing the native handle of the object being constructed.</param>
54     protected LayoutFactory(ConstructingHandle ch) : base(ch)
55     {
56     }
57
58     /// <summary>Initializes a new instance of the <see cref="LayoutFactory"/> class.
59     /// Internal usage: Constructs an instance from a native pointer. This is used when interacting with C code and should not be used directly.</summary>
60     /// <param name="wh">The native pointer to be wrapped.</param>
61     protected LayoutFactory(Efl.Eo.Globals.WrappingHandle wh) : base(wh)
62     {
63     }
64
65     /// <summary>Initializes a new instance of the <see cref="LayoutFactory"/> class.
66     /// Internal usage: Constructor to forward the wrapper initialization to the root class that interfaces with native code. Should not be used directly.</summary>
67     /// <param name="baseKlass">The pointer to the base native Eo class.</param>
68     /// <param name="parent">The Efl.Object parent of this instance.</param>
69     protected LayoutFactory(IntPtr baseKlass, Efl.Object parent) : base(baseKlass, parent)
70     {
71     }
72
73     /// <summary>No description supplied.</summary>
74     /// <param name="klass">The class of the group.</param>
75     /// <param name="group">The group.</param>
76     /// <param name="style">The style to used.</param>
77     virtual public void ThemeConfig(System.String klass, System.String group, System.String style) {
78                                                                                  Efl.Ui.LayoutFactory.NativeMethods.efl_ui_layout_factory_theme_config_ptr.Value.Delegate((IsGeneratedBindingClass ? this.NativeHandle : Efl.Eo.Globals.efl_super(this.NativeHandle, this.NativeClass)),klass, group, style);
79         Eina.Error.RaiseIfUnhandledException();
80                                                          }
81     private static IntPtr GetEflClassStatic()
82     {
83         return Efl.Ui.LayoutFactory.efl_ui_layout_factory_class_get();
84     }
85     /// <summary>Wrapper for native methods and virtual method delegates.
86     /// For internal use by generated code only.</summary>
87     public new class NativeMethods : Efl.Ui.CachingFactory.NativeMethods
88     {
89         private static Efl.Eo.NativeModule Module = new Efl.Eo.NativeModule(    efl.Libs.Elementary);
90         /// <summary>Gets the list of Eo operations to override.</summary>
91         /// <returns>The list of Eo operations to be overload.</returns>
92         public override System.Collections.Generic.List<Efl_Op_Description> GetEoOps(System.Type type)
93         {
94             var descs = new System.Collections.Generic.List<Efl_Op_Description>();
95             var methods = Efl.Eo.Globals.GetUserMethods(type);
96
97             if (efl_ui_layout_factory_theme_config_static_delegate == null)
98             {
99                 efl_ui_layout_factory_theme_config_static_delegate = new efl_ui_layout_factory_theme_config_delegate(theme_config);
100             }
101
102             if (methods.FirstOrDefault(m => m.Name == "ThemeConfig") != null)
103             {
104                 descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_ui_layout_factory_theme_config"), func = Marshal.GetFunctionPointerForDelegate(efl_ui_layout_factory_theme_config_static_delegate) });
105             }
106
107             descs.AddRange(base.GetEoOps(type));
108             return descs;
109         }
110         /// <summary>Returns the Eo class for the native methods of this class.</summary>
111         /// <returns>The native class pointer.</returns>
112         public override IntPtr GetEflClass()
113         {
114             return Efl.Ui.LayoutFactory.efl_ui_layout_factory_class_get();
115         }
116
117         #pragma warning disable CA1707, CS1591, SA1300, SA1600
118
119         
120         private delegate void efl_ui_layout_factory_theme_config_delegate(System.IntPtr obj, System.IntPtr pd, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))] System.String klass, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))] System.String group, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))] System.String style);
121
122         
123         public delegate void efl_ui_layout_factory_theme_config_api_delegate(System.IntPtr obj, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))] System.String klass, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))] System.String group, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))] System.String style);
124
125         public static Efl.Eo.FunctionWrapper<efl_ui_layout_factory_theme_config_api_delegate> efl_ui_layout_factory_theme_config_ptr = new Efl.Eo.FunctionWrapper<efl_ui_layout_factory_theme_config_api_delegate>(Module, "efl_ui_layout_factory_theme_config");
126
127         private static void theme_config(System.IntPtr obj, System.IntPtr pd, System.String klass, System.String group, System.String style)
128         {
129             Eina.Log.Debug("function efl_ui_layout_factory_theme_config was called");
130             var ws = Efl.Eo.Globals.GetWrapperSupervisor(obj);
131             if (ws != null)
132             {
133                                                                                     
134                 try
135                 {
136                     ((LayoutFactory)ws.Target).ThemeConfig(klass, group, style);
137                 }
138                 catch (Exception e)
139                 {
140                     Eina.Log.Warning($"Callback error: {e.ToString()}");
141                     Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
142                 }
143
144                                                         
145             }
146             else
147             {
148                 efl_ui_layout_factory_theme_config_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)), klass, group, style);
149             }
150         }
151
152         private static efl_ui_layout_factory_theme_config_delegate efl_ui_layout_factory_theme_config_static_delegate;
153
154         #pragma warning restore CA1707, CS1591, SA1300, SA1600
155
156 }
157 }
158 }
159
160 }
161
162 #if EFL_BETA
163 #pragma warning disable CS1591
164 public static class Efl_UiLayoutFactory_ExtensionMethods {
165 }
166 #pragma warning restore CS1591
167 #endif