public GameViewOnPlayMenu(IFlexibleMenuItemProvider itemProvider, int selectionIndex, FlexibleMenuModifyItemUI modifyItemUi, IGameViewOnPlayMenuUser gameView, bool showFullscreenOptions = true) : base(itemProvider, selectionIndex, modifyItemUi, gameView.OnPlayPopupSelection) { m_GameView = gameView; m_ShowFullscreenOptions = showFullscreenOptions; m_ItemProvider = itemProvider; }
internal static void GameViewOnPlayPopup(Rect buttonRect, int selectedIndex, IGameViewOnPlayMenuUser gameView, GUIStyle guiStyle) { var text = GameViewOnPlayMenu.GetOnPlayBehaviorName(selectedIndex); if (EditorGUI.DropdownButton(buttonRect, GUIContent.Temp(text), FocusType.Passive, guiStyle)) { var menuData = new GameViewOnPlayMenuItemProvider(); var flexibleMenu = new GameViewOnPlayMenu(menuData, selectedIndex, null, gameView); PopupWindow.Show(buttonRect, flexibleMenu); } }
internal static void GameViewOnPlayPopup(int selectedIndex, IGameViewOnPlayMenuUser gameView, GUIStyle style, params GUILayoutOption[] options) { s_LastRect = GetControlRect(false, EditorGUI.kSingleLineHeight, style, options); EditorGUI.GameViewOnPlayPopup(s_LastRect, selectedIndex, gameView, style); }
public static void SetFocusedToggle(IGameViewOnPlayMenuUser view, bool newValue) { UncheckFocusToggleOnAllViews(); view.playFocused = newValue; }