private void CommandsGUI()
{
bool flag = Event.current.type == EventType.ExecuteCommand;
string commandName = Event.current.commandName;
if (commandName != null)
{
int num;
if (<>f__switch$map2 == null)
{
Dictionary<string, int> dictionary = new Dictionary<string, int>(9) {
{
"Find",
0
},
{
"FrameSelected",
1
},
{
"FrameSelectedWithLock",
2
},
{
"SoftDelete",
3
},
{
"Delete",
3
},
{
"Duplicate",
4
},
{
"Copy",
5
},
{
"Paste",
6
},
{
"SelectAll",
7
}
};
<>f__switch$map2 = dictionary;
}
if (<>f__switch$map2.TryGetValue(commandName, out num))
{
switch (num)
{
case 0:
if (flag)
{
base.FocusSearchField();
}
Event.current.Use();
break;
case 1:
if (flag)
{
bool lockView = (EditorApplication.timeSinceStartup - this.lastFramingTime) < 0.5;
this.FrameSelected(lockView);
this.lastFramingTime = EditorApplication.timeSinceStartup;
}
Event.current.Use();
break;
case 2:
if (flag)
{
this.FrameSelected(true);
}
Event.current.Use();
break;
case 3:
if (flag)
{
Unsupported.DeleteGameObjectSelection();
}
Event.current.Use();
break;
case 4:
if (flag)
{
Unsupported.DuplicateGameObjectsUsingPasteboard();
}
Event.current.Use();
break;
case 5:
if (flag)
{
Unsupported.CopyGameObjectsToPasteboard();
}
Event.current.Use();
break;
case 6:
if (flag)
{
Unsupported.PasteGameObjectsFromPasteboard();
}
Event.current.Use();
break;
case 7:
if (flag)
{
Selection.objects = Object.FindObjectsOfType(typeof(GameObject));
}
Event.current.Use();
break;
}
}
}
}