private void OnClosePressed()
    {
        OnCloseEvent?.Invoke();
        contentAnimator.Hide(true);

        AudioScriptableObjects.dialogClose.Play(true);
    }
예제 #2
0
    public void Hide(bool instant)
    {
        if (instant)
        {
            showHideAnimator.Hide(true);

            AudioScriptableObjects.dialogClose.Play(true);
        }
        else
        {
            timer        = idleTime;
            this.enabled = true;
        }
    }
예제 #3
0
    internal void ShowMoreMenu(bool visible, bool instant = false)
    {
        if (visible)
        {
            if (!moreMenuAnimator.gameObject.activeInHierarchy)
            {
                moreMenuAnimator.gameObject.SetActive(true);
            }

            moreMenuAnimator.Show(instant);
        }
        else
        {
            if (!moreMenuAnimator.gameObject.activeInHierarchy)
            {
                moreMenuAnimator.gameObject.SetActive(false);
            }
            else
            {
                moreMenuAnimator.Hide(instant);
            }
        }

        OnMoreMenuOpened?.Invoke(visible);
    }
    IEnumerator HideRoutine()
    {
        yield return(new WaitForSeconds(HIDE_DELAY));

        showHideAnimator.Hide();
        hideRoutine = null;
    }
 void Hide()
 {
     StartDelayRoutine(setHideDelay, () =>
     {
         showHideAnimator.Hide();
     });
 }
예제 #6
0
 public void HideMenu()
 {
     if (menuShowHideAnimator.isVisible)
     {
         menuShowHideAnimator.Hide();
         CommonScriptableObjects.isProfileHUDOpen.Set(false);
     }
 }
예제 #7
0
 void IOwnersPopupView.Hide(bool instant)
 {
     showHideAnimator.Hide();
     if (instant)
     {
         gameObject.SetActive(false);
     }
 }
예제 #8
0
 internal void HideMenu()
 {
     if (menuShowHideAnimator.isVisible)
     {
         menuShowHideAnimator.Hide();
         CommonScriptableObjects.isProfileHUDOpen.Set(false);
         OnClose?.Invoke();
     }
 }
        public void Initialize(IHUD hudController, ISettingsPanelHUDController settingsPanelController)
        {
            this.hudController           = hudController;
            this.settingsPanelController = settingsPanelController;

            openAction.OnTriggered += OpenAction_OnTriggered;

            resetAllButton.onClick.AddListener(ShowResetAllConfirmation);
            resetAllCancelButton.onClick.AddListener(HideResetAllConfirmation);
            resetAllOkButton.onClick.AddListener(ResetAllSettings);

            closeButton.onClick.AddListener(CloseSettingsPanel);
            settingsAnimator.OnWillFinishHide += OnFinishHide;

            CreateSections();
            isOpen = !settingsAnimator.hideOnEnable;
            settingsAnimator.Hide(true);
        }
예제 #10
0
 public void AnimatorShow(bool isVisible)
 {
     if (isVisible)
     {
         showHideAnimator.Show();
     }
     else
     {
         showHideAnimator.Hide();
     }
 }
예제 #11
0
    private IEnumerator ShowCopyToast()
    {
        if (!copyToast.gameObject.activeSelf)
        {
            copyToast.gameObject.SetActive(true);
        }
        copyToast.Show();
        yield return(new WaitForSeconds(COPY_TOAST_VISIBLE_TIME));

        copyToast.Hide();
    }
예제 #12
0
 public void ToggleMenu()
 {
     if (showHideAnimator.isVisible)
     {
         showHideAnimator.Hide();
     }
     else
     {
         showHideAnimator.Show();
     }
 }
예제 #13
0
 internal void ShowMoreMenu(bool visible, bool instant = false)
 {
     if (visible)
     {
         moreMenuAnimator.Show(instant);
     }
     else
     {
         moreMenuAnimator.Hide(instant);
     }
 }
예제 #14
0
 public void SetVisibility(bool visible)
 {
     if (visible && !mainShowHideAnimator.isVisible)
     {
         mainShowHideAnimator.Show();
     }
     else if (!visible && mainShowHideAnimator.isVisible)
     {
         mainShowHideAnimator.Hide();
     }
 }
    protected void Awake()
    {
        crowdCountContainer.SetActive(false);
        eventsContainer.SetActive(false);

        jumpInHoverArea.OnPointerEnter += () =>
        {
            jumpInButtonAnimator.gameObject.SetActive(true);
            jumpInButtonAnimator.Show();
        };
        jumpInHoverArea.OnPointerExit += () => jumpInButtonAnimator.Hide();
        sceneInfoButton.OnPointerDown += () => jumpInButtonAnimator.Hide(true);

        // NOTE: we don't use the pointer down callback to avoid being mistakenly pressed while dragging
        jumpIn.onClick.AddListener(JumpInPressed);

        sceneInfoButton.OnPointerDown += () => OnInfoButtonPointerDown?.Invoke(this);
        sceneInfoButton.OnPointerExit += () => OnInfoButtonPointerExit?.Invoke();

        Initialize();
    }
    internal void ShowBar(bool visible, bool instant = false)
    {
        if (visible)
        {
            taskbarAnimator.Show(instant);
        }
        else
        {
            taskbarAnimator.Hide(instant);
        }

        isBarVisible = visible;
    }
예제 #17
0
 void IBuilderProjectsPanelView.SetVisible(bool visible)
 {
     if (visible)
     {
         if (!gameObject.activeSelf)
         {
             gameObject.SetActive(true);
         }
         showHideAnimator.Show();
     }
     else
     {
         showHideAnimator.Hide();
     }
 }
예제 #18
0
 public void SetVisibility(bool visible)
 {
     if (visible)
     {
         if (!IsActive())
         {
             popup.gameObject.SetActive(true);
         }
         popup.Show();
     }
     else
     {
         popup.Hide();
     }
 }
예제 #19
0
        public void SetVisibility(bool visible)
        {
            closeAction.OnTriggered -= closeActionDelegate;
            if (visible)
            {
                helpAndSupportAnimator.Show();
                closeAction.OnTriggered += closeActionDelegate;
            }
            else
                helpAndSupportAnimator.Hide();

            if (!visible && isOpen)
                OnClose?.Invoke();

            isOpen = visible;
        }
예제 #20
0
        public void SetVisibility(bool visible)
        {
            if (visible)
            {
                helpAndSupportAnimator.Show();
            }
            else
            {
                helpAndSupportAnimator.Hide();
            }

            if (!visible && isOpen)
            {
                OnClose?.Invoke();
            }

            isOpen = visible;
        }
예제 #21
0
    void IUsersAroundListHUDListView.SetVisibility(bool visible)
    {
        if (visible)
        {
            if (!gameObject.activeSelf)
            {
                gameObject.SetActive(true);
            }

            showHideAnimator.Show();
        }
        else
        {
            showHideAnimator.Hide();
            contextMenu.Hide();
            confirmationDialog.Hide();
        }
    }
예제 #22
0
        public void SetVisibility(bool visible)
        {
            if (visible)
            {
                goToGenesisPlazaAnimator.Show();
            }
            else
            {
                goToGenesisPlazaAnimator.Hide();
            }

            if (!visible && isOpen)
            {
                OnClose?.Invoke();
            }

            isOpen = visible;
        }
예제 #23
0
    public void SetLineIndicator(bool on)
    {
        if (lineOnIndicator != null)
        {
            if (on)
            {
                lineOnIndicator.Show();
            }
            else
            {
                lineOnIndicator.Hide();
            }
        }

        if (lineOffIndicator != null)
        {
            lineOffIndicator.SetActive(!on);
        }
    }
예제 #24
0
    public void Dismiss()
    {
        StopTimer();

        if (showHideAnimator != null)
        {
            showHideAnimator.OnWillFinishHide -= DismissInternal;
            showHideAnimator.OnWillFinishHide += DismissInternal;
            showHideAnimator.Hide();
        }
        else
        {
            DismissInternal();
        }

        if (this != null)
        {
            OnNotificationDismissed?.Invoke(this);
        }
    }
    private IEnumerator PlayMoreMenuAnimations(bool visible, bool instant = false)
    {
        if (visible)
        {
            moreMenuAnimator.Show(instant);

            for (int i = 0; i < sortedButtonsAnimations.Count; i++)
            {
                if (!sortedButtonsAnimations[i].gameObject.activeInHierarchy ||
                    sortedButtonsAnimations[i].lastPlayedAnimation == TaskbarMoreMenuButton.AnimationStatus.In)
                {
                    continue;
                }

                sortedButtonsAnimations[i].PlayAnimation(TaskbarMoreMenuButton.AnimationStatus.In);
                yield return(new WaitForSeconds(timeBetweenAnimations));
            }
        }
        else
        {
            for (int j = sortedButtonsAnimations.Count - 1; j >= 0; j--)
            {
                if (!sortedButtonsAnimations[j].gameObject.activeInHierarchy ||
                    sortedButtonsAnimations[j].lastPlayedAnimation == TaskbarMoreMenuButton.AnimationStatus.Out)
                {
                    continue;
                }

                sortedButtonsAnimations[j].PlayAnimation(TaskbarMoreMenuButton.AnimationStatus.Out);
                yield return(new WaitForSeconds(timeBetweenAnimations));
            }

            if (sortedButtonsAnimations.Count > 0)
            {
                yield return(new WaitForSeconds(sortedButtonsAnimations[0].GetAnimationLenght()));
            }

            moreMenuAnimator.Hide(instant);
        }
    }
예제 #26
0
        public void SetVisibility(bool visible)
        {
            if (visible && !isOpen)
            {
                AudioScriptableObjects.dialogOpen.Play(true);
            }
            else if (isOpen)
            {
                AudioScriptableObjects.dialogClose.Play(true);
            }

            if (visible)
            {
                settingsAnimator.Show();
            }
            else
            {
                settingsAnimator.Hide();
            }

            isOpen = visible;
        }
    internal void ShowMenu(bool visible, bool instant = false)
    {
        if (visible)
        {
            if (!menuAnimator.gameObject.activeInHierarchy)
            {
                menuAnimator.gameObject.SetActive(true);
            }

            menuAnimator.Show(instant);
        }
        else
        {
            if (!menuAnimator.gameObject.activeInHierarchy)
            {
                menuAnimator.gameObject.SetActive(false);
            }
            else
            {
                menuAnimator.Hide(instant);
            }
        }
    }
예제 #28
0
        public void SetVisibility(bool visible)
        {
            if (visible && !isOpen)
            {
                AudioScriptableObjects.dialogOpen.Play(true);
            }
            else if (isOpen)
            {
                AudioScriptableObjects.dialogClose.Play(true);
            }

            closeAction.OnTriggered -= closeActionDelegate;
            if (visible)
            {
                closeAction.OnTriggered += closeActionDelegate;
                settingsAnimator.Show();
            }
            else
            {
                settingsAnimator.Hide();
            }

            isOpen = visible;
        }
 public void Hide()
 {
     showHideAnimator.Hide();
 }
예제 #30
0
 public void OnPointerExit(PointerEventData eventData)
 {
     labelContainer.Hide();
 }