Пример #1
0
 protected override void OnEnable()
 {
     base.OnEnable();
     m_ShouldRecalculateClipRects = true;
     ClipperRegistry.Register(this);
     NewRect2DMaskUtil.Notify2DMaskStateChanged(this);
 }
Пример #2
0
 protected override void OnDisable()
 {
     base.OnDisable();
     m_Clippers.Clear();
     m_ClipTargets.Clear();
     ClipperRegistry.Unregister(this);
     NewRect2DMaskUtil.Notify2DMaskStateChanged(this);
 }
    public static int Cull(IntPtr l)
    {
        int result;

        try
        {
            ClipperRegistry clipperRegistry = (ClipperRegistry)LuaObject.checkSelf(l);
            clipperRegistry.Cull();
            LuaObject.pushValue(l, true);
            result = 1;
        }
        catch (Exception e)
        {
            result = LuaObject.error(l, e);
        }
        return(result);
    }
    public static int Unregister_s(IntPtr l)
    {
        int result;

        try
        {
            IClipper c;
            LuaObject.checkType <IClipper>(l, 1, out c);
            ClipperRegistry.Unregister(c);
            LuaObject.pushValue(l, true);
            result = 1;
        }
        catch (Exception e)
        {
            result = LuaObject.error(l, e);
        }
        return(result);
    }
Пример #5
0
 private void OnEnable()
 {
     ClipperRegistry.Register(this);
 }
Пример #6
0
 private void OnDisable()
 {
     ClipperRegistry.Unregister(this);
 }