Esempio n. 1
0
        private static void DisplayCommands(CommandConsoleWindow window, bool ignoreMaxCommands = false)
        {
            int index = 0;

            if (window.MouseActivity)
            {
                window.MouseOverField = false;
            }

            if (window.CommandResult == null)
            {
                return;
            }

            foreach (var x in window.CommandResult)
            {
                if (index >= CommandManager.MaxCommandShown && !ignoreMaxCommands)
                {
                    break;
                }

                CommandDisplay.DisplayCommandInSearch(x, index, window.SelectedIndex,
                                                      window.MouseActivity, window.ForceValidationKeyPressed, window.SearchTerms);

                if (window.MouseActivity &&
                    GUILayoutUtility.GetLastRect().Contains(Event.current.mousePosition))
                {
                    window.SelectedIndex  = index;
                    window.MouseOverField = true;
                    window.Repaint();
                }

                index++;
            }
        }
Esempio n. 2
0
        private static void DisplayCommandDetails(ParametricCommandExecution execution)
        {
            GUILayout.BeginVertical(MonkeyStyle.Instance.ParametricMethodMethodGroup,
                                    GUILayout.ExpandWidth(true), GUILayout.ExpandHeight(true));

            CommandDisplay.DisplayCommandTitle(false, execution.Info, null);
            CommandDisplay.DisplayCommandHelp(execution.Info, false, true);

            GUILayout.FlexibleSpace();
            GUILayout.EndVertical();
        }
Esempio n. 3
0
        private void OnGUI()
        {
            GUILayout.BeginVertical();

            int i = 0;

            foreach (CommandInfo commandInfo in RightClickContextualCommand)
            {
                CommandDisplay.DisplayCommandInSearch(commandInfo, i, -1, true, true, "");
                i++;
            }
            GUILayout.EndVertical();
        }