void Initialize() { mainPanel.gameObject.SetActive(true); viewPanel.gameObject.SetActive(true); photoPanel.gameObject.SetActive(true); optionPanel.gameObject.SetActive(true); mainPanel.SetupPositions(Vector3.zero, new Vector3(-ScreenWidth, 0.0f, 0.0f)); viewPanel.SetupPositions(Vector3.zero, new Vector3(ScreenWidth, 0.0f, 0.0f)); photoPanel.SetupPositions(Vector3.zero, new Vector3(-ScreenWidth, 0.0f, 0.0f)); optionPanel.SetupPositions(Vector3.zero, new Vector3(ScreenWidth, 0.0f, 0.0f)); mainPanel.Open(true); viewPanel.Close(true); photoPanel.Open(true); optionPanel.Close(true); InitializeOptionPanels(); float side = Mathf.Min(mainImage.rectTransform.sizeDelta.x, mainImage.rectTransform.sizeDelta.y); mainImage.rectTransform.sizeDelta = new Vector2(side, side); }
void _OpenViewPanel(Texture2D snappedPic) { (viewPanel as UIViewPanel).SetupPhotoImage(snappedPic); mainPanel.Close(); photoPanel.Close(); viewPanel.Open(); }
public void ClosePanel(UIPanel uIPanel) { if (uIPanel != null) { _panelList.Remove(uIPanel); if (uIPanel.gameObject != null) { uIPanel.Close(); } } }
public void Close() { Window.Close(); GameManager.Instance.CurrentWindow = null; if (isOpen && PauseWhileOpen) { GameManager.Instance.UnPauseGame(); } isOpen = false; AkSoundEngine.PostEvent("Play_SFX_Window_Close", gameObject); }
void InitializeOptionPanels() { rgbPanel.gameObject.SetActive(true); luminancePanel.gameObject.SetActive(true); fisheyePanel.gameObject.SetActive(true); colorizePanel.gameObject.SetActive(true); resolutionPanel.gameObject.SetActive(true); rgbPanel.SetupPositions(Vector3.zero, new Vector3(ScreenWidth, 0.0f, 0.0f)); luminancePanel.SetupPositions(Vector3.zero, new Vector3(ScreenWidth, 0.0f, 0.0f)); fisheyePanel.SetupPositions(Vector3.zero, new Vector3(ScreenWidth, 0.0f, 0.0f)); colorizePanel.SetupPositions(Vector3.zero, new Vector3(ScreenWidth, 0.0f, 0.0f)); resolutionPanel.SetupPositions(Vector3.zero, new Vector3(ScreenWidth, 0.0f, 0.0f)); rgbPanel.Close(true); luminancePanel.Close(true); fisheyePanel.Close(true); colorizePanel.Close(true); resolutionPanel.Close(true); }
private void Start() { for (int i = 0; i < transform.childCount; ++i) { UIPanel panel = transform.GetChild(i).GetComponent <UIPanel>(); panel.Init(this); panel.Close(); } fsm = GetComponent <Animator>(); NextState(); }
public void OnSceneLoaded(int index) { if (index == titleSceneIndex) { titleMenuPanel.Open(); if (InputDeviceManager.deviceUsesCursor) { Tools.SetCursorActive(true); } } else { titleMenuPanel.Close(); } }
private void HidePanel() { if (!m_initializedAnimator || (mainPanel != null && !mainPanel.gameObject.activeSelf)) { HideImmediate(); m_initializedAnimator = true; } else { standardSubtitleControls.Close(); standardMenuControls.Close(); if (mainPanel != null) { mainPanel.Close(); } } }
/// <summary> /// Close the window by hiding the main panel. Re-enable the bark UI. /// </summary> /// <param name="closedWindowHandler">Closed window handler.</param> public override void CloseWindow(System.Action closedWindowHandler) { closedWindowHandler(); mainPanel.Close(); onClose.Invoke(); }
public void ClosePanel() { panel.Close(); }