#define EFL_BETA
#pragma warning disable CS1591
using System;
using System.Runtime.InteropServices;
using System.Collections.Generic;
using System.Linq;
using System.Threading;
using System.ComponentModel;
namespace Efl {
/// Efl control interface
/// This is a BETA class. It can be modified or removed in the future. Do not use it for product development.
[Efl.IControlConcrete.NativeMethods]
[Efl.Eo.BindingEntity]
public interface IControl :
Efl.Eo.IWrapper, IDisposable
{
/// Control the priority of the object.
/// The priority of the object
int GetPriority();
/// Control the priority of the object.
/// The priority of the object
void SetPriority(int priority);
/// Controls whether the object is suspended or not.
/// Controls whether the object is suspended or not.
bool GetSuspend();
/// Controls whether the object is suspended or not.
/// Controls whether the object is suspended or not.
void SetSuspend(bool suspend);
/// Control the priority of the object.
/// The priority of the object
int Priority {
get;
set;
}
/// Controls whether the object is suspended or not.
/// Controls whether the object is suspended or not.
bool Suspend {
get;
set;
}
}
/// Efl control interface
/// This is a BETA class. It can be modified or removed in the future. Do not use it for product development.
sealed public class IControlConcrete :
Efl.Eo.EoWrapper
, IControl
{
/// Pointer to the native class description.
public override System.IntPtr NativeClass
{
get
{
if (((object)this).GetType() == typeof(IControlConcrete))
{
return GetEflClassStatic();
}
else
{
return Efl.Eo.ClassRegister.klassFromType[((object)this).GetType()];
}
}
}
/// Subclasses should override this constructor if they are expected to be instantiated from native code.
/// Do not call this constructor directly.
/// Tag struct storing the native handle of the object being constructed.
private IControlConcrete(ConstructingHandle ch) : base(ch)
{
}
[System.Runtime.InteropServices.DllImport("libefl.so.1")] internal static extern System.IntPtr
efl_control_interface_get();
/// Initializes a new instance of the class.
/// Internal usage: This is used when interacting with C code and should not be used directly.
/// The native pointer to be wrapped.
private IControlConcrete(Efl.Eo.Globals.WrappingHandle wh) : base(wh)
{
}
/// Control the priority of the object.
/// The priority of the object
public int GetPriority() {
var _ret_var = Efl.IControlConcrete.NativeMethods.efl_control_priority_get_ptr.Value.Delegate(this.NativeHandle);
Eina.Error.RaiseIfUnhandledException();
return _ret_var;
}
/// Control the priority of the object.
/// The priority of the object
public void SetPriority(int priority) {
Efl.IControlConcrete.NativeMethods.efl_control_priority_set_ptr.Value.Delegate(this.NativeHandle,priority);
Eina.Error.RaiseIfUnhandledException();
}
/// Controls whether the object is suspended or not.
/// Controls whether the object is suspended or not.
public bool GetSuspend() {
var _ret_var = Efl.IControlConcrete.NativeMethods.efl_control_suspend_get_ptr.Value.Delegate(this.NativeHandle);
Eina.Error.RaiseIfUnhandledException();
return _ret_var;
}
/// Controls whether the object is suspended or not.
/// Controls whether the object is suspended or not.
public void SetSuspend(bool suspend) {
Efl.IControlConcrete.NativeMethods.efl_control_suspend_set_ptr.Value.Delegate(this.NativeHandle,suspend);
Eina.Error.RaiseIfUnhandledException();
}
/// Control the priority of the object.
/// The priority of the object
public int Priority {
get { return GetPriority(); }
set { SetPriority(value); }
}
/// Controls whether the object is suspended or not.
/// Controls whether the object is suspended or not.
public bool Suspend {
get { return GetSuspend(); }
set { SetSuspend(value); }
}
private static IntPtr GetEflClassStatic()
{
return Efl.IControlConcrete.efl_control_interface_get();
}
/// Wrapper for native methods and virtual method delegates.
/// For internal use by generated code only.
public new class NativeMethods : Efl.Eo.EoWrapper.NativeMethods
{
private static Efl.Eo.NativeModule Module = new Efl.Eo.NativeModule( efl.Libs.Efl);
/// Gets the list of Eo operations to override.
/// The list of Eo operations to be overload.
public override System.Collections.Generic.List GetEoOps(System.Type type)
{
var descs = new System.Collections.Generic.List();
var methods = Efl.Eo.Globals.GetUserMethods(type);
if (efl_control_priority_get_static_delegate == null)
{
efl_control_priority_get_static_delegate = new efl_control_priority_get_delegate(priority_get);
}
if (methods.FirstOrDefault(m => m.Name == "GetPriority") != null)
{
descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_control_priority_get"), func = Marshal.GetFunctionPointerForDelegate(efl_control_priority_get_static_delegate) });
}
if (efl_control_priority_set_static_delegate == null)
{
efl_control_priority_set_static_delegate = new efl_control_priority_set_delegate(priority_set);
}
if (methods.FirstOrDefault(m => m.Name == "SetPriority") != null)
{
descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_control_priority_set"), func = Marshal.GetFunctionPointerForDelegate(efl_control_priority_set_static_delegate) });
}
if (efl_control_suspend_get_static_delegate == null)
{
efl_control_suspend_get_static_delegate = new efl_control_suspend_get_delegate(suspend_get);
}
if (methods.FirstOrDefault(m => m.Name == "GetSuspend") != null)
{
descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_control_suspend_get"), func = Marshal.GetFunctionPointerForDelegate(efl_control_suspend_get_static_delegate) });
}
if (efl_control_suspend_set_static_delegate == null)
{
efl_control_suspend_set_static_delegate = new efl_control_suspend_set_delegate(suspend_set);
}
if (methods.FirstOrDefault(m => m.Name == "SetSuspend") != null)
{
descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_control_suspend_set"), func = Marshal.GetFunctionPointerForDelegate(efl_control_suspend_set_static_delegate) });
}
return descs;
}
/// Returns the Eo class for the native methods of this class.
/// The native class pointer.
public override IntPtr GetEflClass()
{
return Efl.IControlConcrete.efl_control_interface_get();
}
#pragma warning disable CA1707, CS1591, SA1300, SA1600
private delegate int efl_control_priority_get_delegate(System.IntPtr obj, System.IntPtr pd);
public delegate int efl_control_priority_get_api_delegate(System.IntPtr obj);
public static Efl.Eo.FunctionWrapper efl_control_priority_get_ptr = new Efl.Eo.FunctionWrapper(Module, "efl_control_priority_get");
private static int priority_get(System.IntPtr obj, System.IntPtr pd)
{
Eina.Log.Debug("function efl_control_priority_get was called");
var ws = Efl.Eo.Globals.GetWrapperSupervisor(obj);
if (ws != null)
{
int _ret_var = default(int);
try
{
_ret_var = ((IControl)ws.Target).GetPriority();
}
catch (Exception e)
{
Eina.Log.Warning($"Callback error: {e.ToString()}");
Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
}
return _ret_var;
}
else
{
return efl_control_priority_get_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)));
}
}
private static efl_control_priority_get_delegate efl_control_priority_get_static_delegate;
private delegate void efl_control_priority_set_delegate(System.IntPtr obj, System.IntPtr pd, int priority);
public delegate void efl_control_priority_set_api_delegate(System.IntPtr obj, int priority);
public static Efl.Eo.FunctionWrapper efl_control_priority_set_ptr = new Efl.Eo.FunctionWrapper(Module, "efl_control_priority_set");
private static void priority_set(System.IntPtr obj, System.IntPtr pd, int priority)
{
Eina.Log.Debug("function efl_control_priority_set was called");
var ws = Efl.Eo.Globals.GetWrapperSupervisor(obj);
if (ws != null)
{
try
{
((IControl)ws.Target).SetPriority(priority);
}
catch (Exception e)
{
Eina.Log.Warning($"Callback error: {e.ToString()}");
Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
}
}
else
{
efl_control_priority_set_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)), priority);
}
}
private static efl_control_priority_set_delegate efl_control_priority_set_static_delegate;
[return: MarshalAs(UnmanagedType.U1)]
private delegate bool efl_control_suspend_get_delegate(System.IntPtr obj, System.IntPtr pd);
[return: MarshalAs(UnmanagedType.U1)]
public delegate bool efl_control_suspend_get_api_delegate(System.IntPtr obj);
public static Efl.Eo.FunctionWrapper efl_control_suspend_get_ptr = new Efl.Eo.FunctionWrapper(Module, "efl_control_suspend_get");
private static bool suspend_get(System.IntPtr obj, System.IntPtr pd)
{
Eina.Log.Debug("function efl_control_suspend_get was called");
var ws = Efl.Eo.Globals.GetWrapperSupervisor(obj);
if (ws != null)
{
bool _ret_var = default(bool);
try
{
_ret_var = ((IControl)ws.Target).GetSuspend();
}
catch (Exception e)
{
Eina.Log.Warning($"Callback error: {e.ToString()}");
Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
}
return _ret_var;
}
else
{
return efl_control_suspend_get_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)));
}
}
private static efl_control_suspend_get_delegate efl_control_suspend_get_static_delegate;
private delegate void efl_control_suspend_set_delegate(System.IntPtr obj, System.IntPtr pd, [MarshalAs(UnmanagedType.U1)] bool suspend);
public delegate void efl_control_suspend_set_api_delegate(System.IntPtr obj, [MarshalAs(UnmanagedType.U1)] bool suspend);
public static Efl.Eo.FunctionWrapper efl_control_suspend_set_ptr = new Efl.Eo.FunctionWrapper(Module, "efl_control_suspend_set");
private static void suspend_set(System.IntPtr obj, System.IntPtr pd, bool suspend)
{
Eina.Log.Debug("function efl_control_suspend_set was called");
var ws = Efl.Eo.Globals.GetWrapperSupervisor(obj);
if (ws != null)
{
try
{
((IControl)ws.Target).SetSuspend(suspend);
}
catch (Exception e)
{
Eina.Log.Warning($"Callback error: {e.ToString()}");
Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
}
}
else
{
efl_control_suspend_set_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)), suspend);
}
}
private static efl_control_suspend_set_delegate efl_control_suspend_set_static_delegate;
#pragma warning restore CA1707, CS1591, SA1300, SA1600
}
}
}
#if EFL_BETA
#pragma warning disable CS1591
public static class EflIControlConcrete_ExtensionMethods {
public static Efl.BindableProperty Priority(this Efl.Ui.ItemFactory fac, Efl.Csharp.ExtensionTagmagic = null) where T : Efl.IControl {
return new Efl.BindableProperty("priority", fac);
}
public static Efl.BindableProperty Suspend(this Efl.Ui.ItemFactory fac, Efl.Csharp.ExtensionTagmagic = null) where T : Efl.IControl {
return new Efl.BindableProperty("suspend", fac);
}
}
#pragma warning restore CS1591
#endif