Exemple #1
0
        protected override void OnNavigatedTo(NavigationEventArgs eventArgs)
        {
            base.OnNavigatedTo(eventArgs);
            App.CurrentInstance.InstanceViewModel.IsPageTypeNotHome    = false;
            App.CurrentInstance.InstanceViewModel.IsPageTypeMtpDevice  = false;
            App.CurrentInstance.InstanceViewModel.IsPageTypeRecycleBin = false;
            App.CurrentInstance.InstanceViewModel.IsPageTypeCloudDrive = false;
            var parameters = eventArgs.Parameter.ToString();

            Frame rootFrame        = Window.Current.Content as Frame;
            var   instanceTabsView = rootFrame.Content as InstanceTabsView;

            instanceTabsView.SetSelectedTabInfo(parameters, null);
            instanceTabsView.TabStrip_SelectionChanged(null, null);
            App.CurrentInstance.NavigationToolbar.CanRefresh          = false;
            App.CurrentInstance.NavigationToolbar.CanGoBack           = App.CurrentInstance.ContentFrame.CanGoBack;
            App.CurrentInstance.NavigationToolbar.CanGoForward        = App.CurrentInstance.ContentFrame.CanGoForward;
            App.CurrentInstance.NavigationToolbar.CanNavigateToParent = false;

            // Clear the path UI and replace with Favorites
            App.CurrentInstance.NavigationToolbar.PathComponents.Clear();
            string      componentLabel = parameters;
            string      tag            = parameters;
            PathBoxItem item           = new PathBoxItem()
            {
                Title = componentLabel,
                Path  = tag,
            };

            App.CurrentInstance.NavigationToolbar.PathComponents.Add(item);
        }
Exemple #2
0
        protected override async void OnNavigatedTo(NavigationEventArgs eventArgs)
        {
            base.OnNavigatedTo(eventArgs);
            var parameters = eventArgs.Parameter as NavigationArguments;

            AppInstance = parameters.AssociatedTabInstance;
            AppInstance.InstanceViewModel.IsPageTypeNotHome    = false;
            AppInstance.InstanceViewModel.IsPageTypeMtpDevice  = false;
            AppInstance.InstanceViewModel.IsPageTypeRecycleBin = false;
            AppInstance.InstanceViewModel.IsPageTypeCloudDrive = false;
            MainPage.MultitaskingControl?.UpdateSelectedTab(parameters.NavPathParam, null);
            AppInstance.NavigationToolbar.CanRefresh          = false;
            AppInstance.NavigationToolbar.CanGoBack           = AppInstance.ContentFrame.CanGoBack;
            AppInstance.NavigationToolbar.CanGoForward        = AppInstance.ContentFrame.CanGoForward;
            AppInstance.NavigationToolbar.CanNavigateToParent = false;

            // Set path of working directory empty
            await AppInstance.FilesystemViewModel.SetWorkingDirectory("Home");

            // Clear the path UI and replace with Favorites
            AppInstance.NavigationToolbar.PathComponents.Clear();
            string      componentLabel = parameters.NavPathParam;
            string      tag            = parameters.NavPathParam;
            PathBoxItem item           = new PathBoxItem()
            {
                Title = componentLabel,
                Path  = tag,
            };

            AppInstance.NavigationToolbar.PathComponents.Add(item);
        }
Exemple #3
0
        protected override void OnNavigatedTo(NavigationEventArgs eventArgs)
        {
            base.OnNavigatedTo(eventArgs);
            App.InteractionViewModel.IsPageTypeNotHome       = false;
            App.InteractionViewModel.IsPageTypeNotRecycleBin = true;
            var parameters = eventArgs.Parameter.ToString();

            Locations.ItemLoader.itemsAdded.Clear();
            Locations.ItemLoader.DisplayItems();
            recentItemsCollection.Clear();
            PopulateRecentsList();
            Frame rootFrame        = Window.Current.Content as Frame;
            var   instanceTabsView = rootFrame.Content as InstanceTabsView;

            instanceTabsView.SetSelectedTabInfo(parameters, null);
            instanceTabsView.TabStrip_SelectionChanged(null, null);
            App.CurrentInstance.NavigationToolbar.CanRefresh = false;
            App.PS.IsEnabled = false;
            App.CurrentInstance.NavigationToolbar.CanGoBack           = App.CurrentInstance.ContentFrame.CanGoBack;
            App.CurrentInstance.NavigationToolbar.CanGoForward        = App.CurrentInstance.ContentFrame.CanGoForward;
            App.CurrentInstance.NavigationToolbar.CanNavigateToParent = false;

            // Clear the path UI and replace with Favorites
            App.CurrentInstance.NavigationToolbar.PathComponents.Clear();
            string      componentLabel = parameters;
            string      tag            = parameters;
            PathBoxItem item           = new PathBoxItem()
            {
                Title = componentLabel,
                Path  = tag,
            };

            App.CurrentInstance.NavigationToolbar.PathComponents.Add(item);
        }
Exemple #4
0
        protected override void OnNavigatedTo(NavigationEventArgs eventArgs)
        {
            base.OnNavigatedTo(eventArgs);
            var parameters = eventArgs.Parameter.ToString();

            Locations.ItemLoader.itemsAdded.Clear();
            Locations.ItemLoader.DisplayItems();
            recentItemsCollection.Clear();
            PopulateRecentsList();
            Frame rootFrame        = Window.Current.Content as Frame;
            var   instanceTabsView = rootFrame.Content as InstanceTabsView;

            instanceTabsView.SetSelectedTabInfo(parameters, null);
            instanceTabsView.TabStrip_SelectionChanged(null, null);
            App.CurrentInstance.CanRefresh = false;
            App.PS.isEnabled = false;
            (App.CurrentInstance.OperationsControl as RibbonArea).RibbonViewModel.AlwaysPresentCommands.isEnabled = false;
            (App.CurrentInstance.OperationsControl as RibbonArea).RibbonViewModel.LayoutItems.isEnabled           = false;
            App.CurrentInstance.CanNavigateToParent = false;
            // Clear the path UI and replace with Favorites
            App.CurrentInstance.PathComponents.Clear();

            string      componentLabel = parameters;
            string      tag            = parameters;
            PathBoxItem item           = new PathBoxItem()
            {
                Title = componentLabel,
                Path  = tag,
            };

            App.CurrentInstance.PathComponents.Add(item);


            //SetPageContentVisibility(parameters);
        }
Exemple #5
0
        protected override void OnNavigatedTo(NavigationEventArgs eventArgs)
        {
            base.OnNavigatedTo(eventArgs);
            var parameters = eventArgs.Parameter.ToString();

            Locations.ItemLoader.itemsAdded.Clear();
            Locations.ItemLoader.DisplayItems();
            recentItemsCollection.Clear();
            PopulateRecentsList();
            Frame rootFrame        = Window.Current.Content as Frame;
            var   instanceTabsView = rootFrame.Content as InstanceTabsView;

            instanceTabsView.SetSelectedTabInfo(parameters, null);
            instanceTabsView.TabStrip_SelectionChanged(null, null);
            App.OccupiedInstance.RibbonArea.Refresh.IsEnabled = false;
            App.PS.isEnabled = false;
            App.OccupiedInstance.AlwaysPresentCommands.isEnabled = false;
            App.OccupiedInstance.LayoutItems.isEnabled           = false;
            App.OccupiedInstance.RibbonArea.Up.IsEnabled         = false;
            // Clear the path UI and replace with Favorites
            App.OccupiedInstance.pathBoxItems.Clear();
            //Style tabStyleFixed = App.selectedTabInstance.accessiblePathTabView.Resources["PathSectionTabStyle"] as Style;

            string      componentLabel = parameters;
            string      tag            = parameters;
            PathBoxItem item           = new PathBoxItem()
            {
                Title = componentLabel,
                Path  = tag,
            };

            App.OccupiedInstance.pathBoxItems.Add(item);


            //SetPageContentVisibility(parameters);
        }