예제 #1
0
        protected override async void OnViewLoaded(object view)
        {
            ToolPanelsContent.ActivateItem(IoC.Get <IOutput>());

            if (Properties.Settings.Default.ShowNavigationPanelOnOpen)
            {
                ShellLayoutController.Current.LeftContentIsVisible = true;
            }

            if (Properties.Settings.Default.ShowStartPageOnOpen)
            {
                await MainContent.OpenDocument <IStartupDocument>();
            }

            if (Properties.Settings.Default.Diagnostics_ShowManagedMemory)
            {
                StatusBarContent.ActivateContent(new MemoryUsageStatusButton().Start(), StatusBarContentLocation.Right);
            }

            CommandManager.InvalidateRequerySuggested();

            if (!AppConstants.IsDebug)
            {
                _ = Task.Delay(TimeSpan.FromSeconds(30))
                    .ContinueWith(task => { OnUIThread(async() => await AppUpdateManager.Current.CheckForUpdates(false)); })
                    .ConfigureAwait(false);
            }
        }
예제 #2
0
        protected override async void OnViewLoaded(object view)
        {
            if (Properties.Settings.Default.ShowStartPageOnOpen)
            {
                await MainContent.OpenDocument <IStartupDocument>();
            }

            if (Properties.Settings.Default.Diagnostics_ShowManagedMemory)
            {
                StatusBarContent.ActivateContent(new MemoryUsageStatusButton().Start(), StatusBarContentLocation.Right);
            }

            BottomToolPanels.ActivateItem(IoC.Get <IOutput>());
        }
예제 #3
0
 private void OnSettingsPropertyChanged(object sender, PropertyChangedEventArgs e)
 {
     if (e.PropertyName == nameof(Properties.Settings.Default.Diagnostics_ShowManagedMemory))
     {
         if (Properties.Settings.Default.Diagnostics_ShowManagedMemory)
         {
             var usageStatusButton = StatusBarContent.ActivateContent(new MemoryUsageStatusButton(), StatusBarContentLocation.Right) as MemoryUsageStatusButton;
             usageStatusButton?.Start();
         }
         else
         {
             StatusBarContent.DeactivateContent(MemoryUsageStatusButton.ContentIdTag);
         }
     }
 }
예제 #4
0
        protected override async void OnViewLoaded(object view)
        {
            ToolPanelsContent.ActivateItem(IoC.Get <IOutput>());

            if (Properties.Settings.Default.ShowNavigationPanelOnOpen)
            {
                ShellLayoutController.Current.LeftContentIsVisible = true;
            }

            if (Properties.Settings.Default.ShowStartPageOnOpen)
            {
                await MainContent.OpenDocument <IStartupDocument>();
            }

            if (Properties.Settings.Default.Diagnostics_ShowManagedMemory)
            {
                StatusBarContent.ActivateContent(new MemoryUsageStatusButton().Start(), StatusBarContentLocation.Right);
            }

            CommandManager.InvalidateRequerySuggested();
        }