public override void Hide(BaseWindow t, Action <AbstractGoTween> onComplete) { t.CachedTransform.localPosition = _finishVector3; _hideConfig.onCompleteHandler = onComplete; Go.to(t.CachedTransform, AlphaOutDuration, _hideConfig); Go.to(t, HideTransitionTime, _hidePanelConfig); }
public override void Show(BaseWindow t, Action <AbstractGoTween> onComplete) { t.CachedTransform.localPosition = _startVector3; t.CachedTransform.localScale = _downscaled; _showConfig.onCompleteHandler = onComplete; Go.to(t.CachedTransform, AlphaInDuration, _showConfig); Go.to(t, ShowTransitionTime, _showPanelConfig); }
public void ShowWindow(string windowName, UnityEngine.Object data = null) { Debug.Log("Show window: " + windowName); if (!_inWindowShow) { _inWindowShow = true; if (_windowMap.ContainsKey(windowName)) { var newWindow = _windowMap[windowName]; if (CurrentWindow != null) { if (CurrentWindow.Id != windowName) { var previous = CurrentWindow; HideWindow(previous.Id, () => { newWindow.Active = true; newWindow.OnInit(); _selectedTransition.Show(newWindow, tween => { CurrentWindow = newWindow; newWindow.OnFocused(); _inWindowShow = false; OnCurrentWindowChange?.Invoke(CurrentWindow); }); }); } else { _inWindowShow = false; } } else { newWindow.Active = true; newWindow.OnInit(); _selectedTransition.Show(newWindow, tween => { CurrentWindow = newWindow; newWindow.OnFocused(); _inWindowShow = false; OnCurrentWindowChange?.Invoke(CurrentWindow); }); } } } }
public void HideWindow(string windowName, Action onComplete = null) { if (!_inWindowHide) { _inWindowHide = true; if (_windowMap.ContainsKey(windowName)) { var window = _windowMap[windowName]; _selectedTransition.Hide(window, tween => { CurrentWindow = null; onComplete?.Invoke(); window.Alpha = 0; window.OnUnfocused(); _inWindowHide = false; }); } } }
public abstract void Hide(BaseWindow t, Action <AbstractGoTween> onComplete);
public abstract void Hide(BaseWindow t, Action onComplete);
public abstract void Show(BaseWindow t, Action onComplete);
public override void Hide(BaseWindow t, Action onComplete) { Debug.Log("Not implemented"); }