Skip to content

Commit 767c15d

Browse files
committed
Fixed hidden flags usage in editor
1 parent cc4cde3 commit 767c15d

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

Project/Assets/LunarConsole/Editor/UI/ActionsAndVariablesWindow.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,11 @@ void OnActionGUI(CAction action)
131131

132132
void OnVariableGUI(CVar cvar)
133133
{
134+
if (cvar.IsHidden)
135+
{
136+
return;
137+
}
138+
134139
if (cvar.IsDefault)
135140
{
136141
OnVariableFieldGUI(cvar);

Project/Assets/LunarConsole/Scripts/Actions/CVar.cs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ public bool IsValid
7474
}
7575
}
7676

77+
[Flags]
7778
public enum CFlags
7879
{
7980
/// <summary>
@@ -377,6 +378,11 @@ public CFlags Flags
377378
get { return m_flags; }
378379
}
379380

381+
public bool IsHidden
382+
{
383+
get { return (m_flags & CFlags.Hidden) != 0; }
384+
}
385+
380386
#endregion
381387

382388
#region Operators

0 commit comments

Comments
 (0)