public virtual void NavigateTo(Navigateable target, NavigationArgs args = null) { HandleExit(target); target.HandleEnter(args ?? new NavigationArgs { current = this }); }
public override void HandleEnter(NavigationArgs args) { if (!args.isReturning) { returnTarget = args.current; } base.HandleEnter(args); }
public void SwitchTo(Navigateable newTab) { if (newTab == activeTab) { return; } activeTab.NavigateTo(newTab, new NavigationArgs { current = activeTab }); activeTab = newTab; }
public void SetDefaultActive(Navigateable tab) { activeTab = tab; activeTab.HandleEnter(null); }
public virtual void HandleExit(Navigateable target) { gameObject.SetActive(false); }