/// <summary> /// Occurs when the navigation item has changed /// </summary> /// <param name="oldValue"></param> /// <param name="newValue"></param> protected virtual void OnNavigationItemChanged(NavigationItem oldValue, NavigationItem newValue) { // update rootitem this.RootItem = newValue?.GetAncestorsAndSelf().LastOrDefault(); }