コード例 #1
0
        public void gcRef(LuaState.UnRefAction act, int r)
        {
            LuaState.UnrefPair item = default(LuaState.UnrefPair);
            item.act = act;
            item.r   = r;
            Queue <LuaState.UnrefPair> obj = this.refQueue;

            lock (obj)
            {
                this.refQueue.Enqueue(item);
            }
        }
コード例 #2
0
 public virtual void Dispose(bool disposeManagedResources)
 {
     if (valueref != 0)
     {
         LuaState.UnRefAction act = (IntPtr l, int r) =>
         {
             LuaDLL.lua_unref(l, r);
         };
         state.gcRef(act, valueref);
         valueref = 0;
     }
 }
コード例 #3
0
ファイル: LuaState.cs プロジェクト: BraedonWooding/slua
 public virtual void Dispose(bool disposeManagedResources)
 {
     if (valueref != 0)
     {
         LuaState.UnRefAction act = (IntPtr ptr, int r) =>
         {
             LuaNativeMethods.lua_unref(ptr, r);
         };
         state.GCRef(act, valueref);
         valueref = 0;
     }
 }
コード例 #4
0
ファイル: LuaVar.cs プロジェクト: nowcoder001/dragonnest_src
 public virtual void Dispose(bool disposeManagedResources)
 {
     if (this.valueref != 0)
     {
         LuaState.UnRefAction act = delegate(IntPtr l, int r)
         {
             LuaDLL.pua_unref(l, r);
         };
         this.state.gcRef(act, this.valueref);
         this.valueref = 0;
     }
 }
コード例 #5
0
 public override void Dispose(bool disposeManagedResources)
 {
     if (valueref != 0)
     {
         LuaState.UnRefAction act = (IntPtr l, int r) =>
         {
             LuaObject.removeDelgate(l, r);
             LuaDLL.lua_unref(l, r);
         };
         state.gcRef(act, valueref);
         valueref = 0;
     }
 }
コード例 #6
0
 public override void Dispose(bool disposeManagedResources)
 {
     if (this.valueref != 0)
     {
         LuaState.UnRefAction act = delegate(IntPtr l, int r)
         {
             LuaObject.removeDelgate(l, r);
             LuaDLL.pua_unref(l, r);
         };
         this.state.gcRef(act, this.valueref);
         this.valueref = 0;
     }
 }
コード例 #7
0
ファイル: LuaState.cs プロジェクト: BraedonWooding/slua
 public override void Dispose(bool disposeManagedResources)
 {
     if (valueref != 0)
     {
         LuaState.UnRefAction act = (IntPtr ptr, int r) =>
         {
             LuaObject.RemoveDelgate(ptr, r);
             LuaNativeMethods.lua_unref(ptr, r);
         };
         state.GCRef(act, valueref);
         valueref = 0;
     }
 }