static public int get_interval(IntPtr l) { try { FairyGUI.LongPressGesture self = (FairyGUI.LongPressGesture)checkSelf(l); pushValue(l, true); pushValue(l, self.interval); return(2); } catch (Exception e) { return(error(l, e)); } }
static public int Cancel(IntPtr l) { try { FairyGUI.LongPressGesture self = (FairyGUI.LongPressGesture)checkSelf(l); self.Cancel(); pushValue(l, true); return(1); } catch (Exception e) { return(error(l, e)); } }
static public int Enable(IntPtr l) { try { FairyGUI.LongPressGesture self = (FairyGUI.LongPressGesture)checkSelf(l); System.Boolean a1; checkType(l, 2, out a1); self.Enable(a1); pushValue(l, true); return(1); } catch (Exception e) { return(error(l, e)); } }
static int Cancel(IntPtr L) { try { ToLua.CheckArgsCount(L, 1); FairyGUI.LongPressGesture obj = (FairyGUI.LongPressGesture)ToLua.CheckObject <FairyGUI.LongPressGesture>(L, 1); obj.Cancel(); return(0); } catch (Exception e) { return(LuaDLL.toluaL_exception(L, e)); } }
static public int set_trigger(IntPtr l) { try { FairyGUI.LongPressGesture self = (FairyGUI.LongPressGesture)checkSelf(l); System.Single v; checkType(l, 2, out v); self.trigger = v; pushValue(l, true); return(1); } catch (Exception e) { return(error(l, e)); } }
static int Enable(IntPtr L) { try { ToLua.CheckArgsCount(L, 2); FairyGUI.LongPressGesture obj = (FairyGUI.LongPressGesture)ToLua.CheckObject <FairyGUI.LongPressGesture>(L, 1); bool arg0 = LuaDLL.luaL_checkboolean(L, 2); obj.Enable(arg0); return(0); } catch (Exception e) { return(LuaDLL.toluaL_exception(L, e)); } }
static public int constructor(IntPtr l) { try { FairyGUI.LongPressGesture o; FairyGUI.GObject a1; checkType(l, 2, out a1); o = new FairyGUI.LongPressGesture(a1); pushValue(l, true); pushValue(l, o); return(2); } catch (Exception e) { return(error(l, e)); } }
static int set_once(IntPtr L) { object o = null; try { o = ToLua.ToObject(L, 1); FairyGUI.LongPressGesture obj = (FairyGUI.LongPressGesture)o; bool arg0 = LuaDLL.luaL_checkboolean(L, 2); obj.once = arg0; return(0); } catch (Exception e) { return(LuaDLL.toluaL_exception(L, e, o, "attempt to index once on a nil value")); } }
static int set_interval(IntPtr L) { object o = null; try { o = ToLua.ToObject(L, 1); FairyGUI.LongPressGesture obj = (FairyGUI.LongPressGesture)o; float arg0 = (float)LuaDLL.luaL_checknumber(L, 2); obj.interval = arg0; return(0); } catch (Exception e) { return(LuaDLL.toluaL_exception(L, e, o, "attempt to index interval on a nil value")); } }
static int get_onAction(IntPtr L) { object o = null; try { o = ToLua.ToObject(L, 1); FairyGUI.LongPressGesture obj = (FairyGUI.LongPressGesture)o; FairyGUI.EventListener ret = obj.onAction; ToLua.PushObject(L, ret); return(1); } catch (Exception e) { return(LuaDLL.toluaL_exception(L, e, o, "attempt to index onAction on a nil value")); } }
static int get_host(IntPtr L) { object o = null; try { o = ToLua.ToObject(L, 1); FairyGUI.LongPressGesture obj = (FairyGUI.LongPressGesture)o; FairyGUI.GObject ret = obj.host; ToLua.PushObject(L, ret); return(1); } catch (Exception e) { return(LuaDLL.toluaL_exception(L, e, o, "attempt to index host on a nil value")); } }
static int get_holdRangeRadius(IntPtr L) { object o = null; try { o = ToLua.ToObject(L, 1); FairyGUI.LongPressGesture obj = (FairyGUI.LongPressGesture)o; int ret = obj.holdRangeRadius; LuaDLL.lua_pushinteger(L, ret); return(1); } catch (Exception e) { return(LuaDLL.toluaL_exception(L, e, o, "attempt to index holdRangeRadius on a nil value")); } }
static int get_once(IntPtr L) { object o = null; try { o = ToLua.ToObject(L, 1); FairyGUI.LongPressGesture obj = (FairyGUI.LongPressGesture)o; bool ret = obj.once; LuaDLL.lua_pushboolean(L, ret); return(1); } catch (Exception e) { return(LuaDLL.toluaL_exception(L, e, o, "attempt to index once on a nil value")); } }
static int get_interval(IntPtr L) { object o = null; try { o = ToLua.ToObject(L, 1); FairyGUI.LongPressGesture obj = (FairyGUI.LongPressGesture)o; float ret = obj.interval; LuaDLL.lua_pushnumber(L, ret); return(1); } catch (Exception e) { return(LuaDLL.toluaL_exception(L, e, o, "attempt to index interval on a nil value")); } }
static int set_holdRangeRadius(IntPtr L) { object o = null; try { o = ToLua.ToObject(L, 1); FairyGUI.LongPressGesture obj = (FairyGUI.LongPressGesture)o; int arg0 = (int)LuaDLL.luaL_checknumber(L, 2); obj.holdRangeRadius = arg0; return(0); } catch (Exception e) { return(LuaDLL.toluaL_exception(L, e, o, "attempt to index holdRangeRadius on a nil value")); } }
void Start() { _mainView = this.GetComponent <UIPanel>().ui; GObject holder = _mainView.GetChild("holder"); _ball = GameObject.Find("Globe").transform; FairyGUI.SwipeGesture gesture1 = new FairyGUI.SwipeGesture(holder); gesture1.onMove.Add(OnSwipeMove); gesture1.onEnd.Add(OnSwipeEnd); FairyGUI.LongPressGesture gesture2 = new FairyGUI.LongPressGesture(holder); gesture2.once = false; gesture2.onAction.Add(OnHold); FairyGUI.PinchGesture gesture3 = new FairyGUI.PinchGesture(holder); gesture3.onAction.Add(OnPinch); FairyGUI.RotationGesture gesture4 = new FairyGUI.RotationGesture(holder); gesture4.onAction.Add(OnRotate); }
static int _CreateFairyGUI_LongPressGesture(IntPtr L) { try { int count = LuaDLL.lua_gettop(L); if (count == 1) { FairyGUI.GObject arg0 = (FairyGUI.GObject)ToLua.CheckObject <FairyGUI.GObject>(L, 1); FairyGUI.LongPressGesture obj = new FairyGUI.LongPressGesture(arg0); ToLua.PushObject(L, obj); return(1); } else { return(LuaDLL.luaL_throw(L, "invalid arguments to ctor method: FairyGUI.LongPressGesture.New")); } } catch (Exception e) { return(LuaDLL.toluaL_exception(L, e)); } }
void Start() { Application.targetFrameRate = 60; GRoot.inst.SetContentScaleFactor(1136, 640); Stage.inst.onKeyDown.Add(OnKeyDown); UIPackage.AddPackage("UI/Gesture"); _mainView = UIPackage.CreateObject("Gesture", "Main").asCom; _mainView.SetSize(GRoot.inst.width, GRoot.inst.height); _mainView.AddRelation(GRoot.inst, RelationType.Size); GRoot.inst.AddChild(_mainView); GObject holder = _mainView.GetChild("holder"); _ball = GameObject.Find("Globe").transform; SwipeGesture gesture1 = new SwipeGesture(holder); gesture1.onMove.Add(OnSwipeMove); gesture1.onEnd.Add(OnSwipeEnd); LongPressGesture gesture2 = new LongPressGesture(holder); gesture2.once = false; gesture2.onAction.Add(OnHold); PinchGesture gesture3 = new PinchGesture(holder); gesture3.onAction.Add(OnPinch); RotationGesture gesture4 = new RotationGesture(holder); gesture4.onAction.Add(OnRotate); }
void Start() { _mainView = this.GetComponent<UIPanel>().ui; GObject holder = _mainView.GetChild("holder"); _ball = GameObject.Find("Globe").transform; FairyGUI.SwipeGesture gesture1 = new FairyGUI.SwipeGesture(holder); gesture1.onMove.Add(OnSwipeMove); gesture1.onEnd.Add(OnSwipeEnd); FairyGUI.LongPressGesture gesture2 = new FairyGUI.LongPressGesture(holder); gesture2.once = false; gesture2.onAction.Add(OnHold); FairyGUI.PinchGesture gesture3 = new FairyGUI.PinchGesture(holder); gesture3.onAction.Add(OnPinch); FairyGUI.RotationGesture gesture4 = new FairyGUI.RotationGesture(holder); gesture4.onAction.Add(OnRotate); }
void Start() { _mainView = this.GetComponent<UIPanel>().ui; _list = _mainView.GetChild("list").asList; _list.itemRenderer = RenderListItem; _list.SetVirtual(); _list.numItems = 1000; _list.onTouchBegin.Add(OnClickList); _mainView.GetChild("box").asCom.onDrop.Add(OnDrop); LongPressGesture gesture = new LongPressGesture(_list); gesture.once = true; gesture.trigger = 1f; gesture.onAction.Add(OnLongPress); }