Пример #1
0
		public static void Indent(float width, FoldoutDraw draw) {
			EditorGUILayout.BeginHorizontal();
			EditorGUILayout.BeginVertical(GUILayout.Width(width));
			GUILayout.Label("");
			EditorGUILayout.EndVertical();
			EditorGUILayout.BeginVertical();
			draw.Invoke();
			EditorGUILayout.EndVertical();
			EditorGUILayout.EndHorizontal();
		}
Пример #2
0
		public static void Foldout(ref bool open, GUIContent content, FoldoutDraw draw, FoldoutDraw moreLabel) {
			GUILayout.BeginHorizontal();
			open = EditorGUILayout.Foldout(open, content);
			if(moreLabel != null)
				moreLabel.Invoke();
			GUILayout.EndHorizontal();
			if(open) {
				Indent(draw);
			}
		}
Пример #3
0
 public static void Indent(float width, FoldoutDraw draw)
 {
     EditorGUILayout.BeginHorizontal();
     EditorGUILayout.BeginVertical(GUILayout.Width(width));
     GUILayout.Label("");
     EditorGUILayout.EndVertical();
     EditorGUILayout.BeginVertical();
     draw.Invoke();
     EditorGUILayout.EndVertical();
     EditorGUILayout.EndHorizontal();
 }
Пример #4
0
 public static void Foldout(ref bool open, GUIContent content, FoldoutDraw draw, FoldoutDraw moreLabel)
 {
     GUILayout.BeginHorizontal();
     open = EditorGUILayout.Foldout(open, content);
     if (moreLabel != null)
     {
         moreLabel.Invoke();
     }
     GUILayout.EndHorizontal();
     if (open)
     {
         Indent(draw);
     }
 }