CheckIfRelated() public static method

Helper function that determines whether the two atlases are related.
public static CheckIfRelated ( UIFont, a, UIFont, b ) : bool
a UIFont,
b UIFont,
return bool
Example #1
0
    public void MarkAsChanged()
    {
        if (this.mReplacement != (UnityEngine.Object)null)
        {
            this.mReplacement.MarkAsChanged();
        }
        this.mSprite = (UISpriteData)null;
        UILabel[] array = NGUITools.FindActive <UILabel>();
        Int32     i     = 0;
        Int32     num   = (Int32)array.Length;

        while (i < num)
        {
            UILabel uilabel = array[i];
            if (uilabel.enabled && NGUITools.GetActive(uilabel.gameObject) && UIFont.CheckIfRelated(this, uilabel.bitmapFont))
            {
                UIFont bitmapFont = uilabel.bitmapFont;
                uilabel.bitmapFont = (UIFont)null;
                uilabel.bitmapFont = bitmapFont;
            }
            i++;
        }
        Int32 j     = 0;
        Int32 count = this.symbols.Count;

        while (j < count)
        {
            this.symbols[j].MarkAsChanged();
            j++;
        }
    }
Example #2
0
    // Token: 0x0600358F RID: 13711 RVA: 0x0010FE28 File Offset: 0x0010E228
    public void MarkAsChanged()
    {
        if (this.mReplacement != null)
        {
            this.mReplacement.MarkAsChanged();
        }
        this.mSprite = null;
        UILabel[] array = NGUITools.FindActive <UILabel>();
        int       i     = 0;
        int       num   = array.Length;

        while (i < num)
        {
            UILabel uilabel = array[i];
            if (uilabel.enabled && NGUITools.GetActive(uilabel.gameObject) && UIFont.CheckIfRelated(this, uilabel.bitmapFont))
            {
                UIFont bitmapFont = uilabel.bitmapFont;
                uilabel.bitmapFont = null;
                uilabel.bitmapFont = bitmapFont;
            }
            i++;
        }
        int j     = 0;
        int count = this.symbols.Count;

        while (j < count)
        {
            this.symbols[j].MarkAsChanged();
            j++;
        }
    }
Example #3
0
    void MarkAsChanged()
    {
        List <UILabel> labels = NGUIEditorTools.FindAll <UILabel>();

        foreach (UILabel lbl in labels)
        {
            if (UIFont.CheckIfRelated(lbl.bitmapFont, mFont))
            {
                lbl.bitmapFont = null;
                lbl.bitmapFont = mFont;
            }
        }
    }
Example #4
0
 static int CheckIfRelated(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 2);
         UIFont arg0 = (UIFont)ToLua.CheckObject <UIFont>(L, 1);
         UIFont arg1 = (UIFont)ToLua.CheckObject <UIFont>(L, 2);
         bool   o    = UIFont.CheckIfRelated(arg0, arg1);
         LuaDLL.lua_pushboolean(L, o);
         return(1);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
Example #5
0
 static public int CheckIfRelated_s(IntPtr l)
 {
     try {
         UIFont a1;
         checkType(l, 1, out a1);
         UIFont a2;
         checkType(l, 2, out a2);
         var ret = UIFont.CheckIfRelated(a1, a2);
         pushValue(l, true);
         pushValue(l, ret);
         return(2);
     }
     catch (Exception e) {
         return(error(l, e));
     }
 }
Example #6
0
 void MarkAsChanged()
 {
     List <UILabel> labels = NGUIEditorTools.FindAll <UILabel>();
     {
         var __list1      = labels;
         var __listCount1 = __list1.Count;
         for (int __i1 = 0; __i1 < __listCount1; ++__i1)
         {
             var lbl = (UILabel)__list1[__i1];
             {
                 if (UIFont.CheckIfRelated(lbl.bitmapFont, mFont))
                 {
                     lbl.bitmapFont = null;
                     lbl.bitmapFont = mFont;
                 }
             }
         }
     }
 }
Example #7
0
    public static int CheckIfRelated_s(IntPtr l)
    {
        int result;

        try
        {
            UIFont a;
            LuaObject.checkType <UIFont>(l, 1, out a);
            UIFont b;
            LuaObject.checkType <UIFont>(l, 2, out b);
            bool b2 = UIFont.CheckIfRelated(a, b);
            LuaObject.pushValue(l, true);
            LuaObject.pushValue(l, b2);
            result = 2;
        }
        catch (Exception e)
        {
            result = LuaObject.error(l, e);
        }
        return(result);
    }
Example #8
0
 public unsafe static long $Invoke1(long instance, long *args)
 {
     return(GCHandledObjects.ObjectToGCHandle(UIFont.CheckIfRelated((UIFont)GCHandledObjects.GCHandleToObject(*args), (UIFont)GCHandledObjects.GCHandleToObject(args[1]))));
 }