상속: GUILayoutEntry
예제 #1
0
 internal LayoutCache()
 {
     this.topLevel = new GUILayoutGroup();
     this.layoutGroups = new GenericStack();
     this.windows = new GUILayoutGroup();
     this.layoutGroups.Push(this.topLevel);
 }
예제 #2
0
 internal LayoutCache(GUILayoutUtility.LayoutCache other)
 {
     this.topLevel = new GUILayoutGroup();
     this.layoutGroups = new GenericStack();
     this.windows = new GUILayoutGroup();
     this.topLevel = other.topLevel;
     this.layoutGroups = other.layoutGroups;
     this.windows = other.windows;
 }
예제 #3
0
 private static void LayoutSingleGroup(GUILayoutGroup i)
 {
     if (!i.isWindow)
     {
         float minWidth = i.minWidth;
         float maxWidth = i.maxWidth;
         i.CalcWidth();
         i.SetHorizontal(i.rect.x, Mathf.Clamp(i.maxWidth, minWidth, maxWidth));
         float minHeight = i.minHeight;
         float maxHeight = i.maxHeight;
         i.CalcHeight();
         i.SetVertical(i.rect.y, Mathf.Clamp(i.maxHeight, minHeight, maxHeight));
     }
     else
     {
         i.CalcWidth();
         Rect rect = Internal_GetWindowRect(i.windowID);
         i.SetHorizontal(rect.x, Mathf.Clamp(rect.width, i.minWidth, i.maxWidth));
         i.CalcHeight();
         i.SetVertical(rect.y, Mathf.Clamp(rect.height, i.minHeight, i.maxHeight));
         Internal_MoveWindow(i.windowID, i.rect);
     }
 }
예제 #4
0
 internal static void LayoutFreeGroup(GUILayoutGroup toplevel)
 {
     foreach (GUILayoutGroup group in toplevel.entries)
     {
         LayoutSingleGroup(group);
     }
     toplevel.ResetCursor();
 }
 internal LayoutCache(GUILayoutUtility.LayoutCache other)
 {
   this.topLevel = other.topLevel;
   this.layoutGroups = other.layoutGroups;
   this.windows = other.windows;
 }
 internal static void LayoutFreeGroup(GUILayoutGroup toplevel)
 {
   using (List<GUILayoutEntry>.Enumerator enumerator = toplevel.entries.GetEnumerator())
   {
     while (enumerator.MoveNext())
       GUILayoutUtility.LayoutSingleGroup((GUILayoutGroup) enumerator.Current);
   }
   toplevel.ResetCursor();
 }
예제 #7
0
 internal LayoutCache(GUILayoutUtility.LayoutCache other)
 {
     this.topLevel     = other.topLevel;
     this.layoutGroups = other.layoutGroups;
     this.windows      = other.windows;
 }