示例#1
0
        private void Navigate(NavigateOrder order)
        {
            var isVisibleTop =
                order.ViewName != ViewNames.ROOT;

            if (isVisibleTop)
            {
                regionManager.Move(RegionNames.TopMenuRegion, typeof(TopMenuView).ToString(), order.Prms);
            }
            else
            {
                regionManager.Clear(RegionNames.TopMenuRegion);
            }

            regionManager.Clear(RegionNames.ProjectContentRegion);

            regionManager.Move(RegionNames.ContentRegion, order.ViewName, order.Prms);
        }
示例#2
0
        public static void Move(this IRegionManager regionManager, string regionName, string viewName, IDictionary <string, object> prms = null)
        {
            regionManager.Clear(regionName);

            var uri = new Uri(viewName, UriKind.Relative);

            var param = new NavigationParameters();

            param.Add(prms);
            regionManager.RequestNavigate(regionName, uri, param);
        }