Cleanup 2

This commit is contained in:
Stefan Markovic 2021-11-19 11:25:33 +01:00
parent a466bb3c14
commit e6c6a8a046
3 changed files with 8 additions and 7 deletions

View file

@ -118,8 +118,6 @@ namespace Microsoft.PowerToys.Settings.UI.WinUI3
}
});
ipcmanager.Start();
// TODO(stefan)
//app.Run();
}
else
{

View file

@ -18,6 +18,6 @@
<TextBlock Style="{StaticResource CaptionTextBlockStyle}" Margin="12,0,0,0" Text="PowerToys" />
</StackPanel>
</Grid>
<local:ShellPage Grid.Row="1" x:Name="shellPage"/>
<local:ShellPage Grid.Row="1"/>
</Grid>
</Window>

View file

@ -33,10 +33,7 @@ namespace Microsoft.PowerToys.Settings.UI.WinUI3
ShellPage.SetRestartAdminSndMessageCallback(msg =>
{
App.GetTwoWayIPCManager()?.Send(msg);
// TODO(stefan)
// isOpen = false;
Environment.Exit(0);
// System.Windows.Application.Current.Shutdown(); // close application
});
// send IPC Message
@ -74,8 +71,14 @@ namespace Microsoft.PowerToys.Settings.UI.WinUI3
ShellPage.SetElevationStatus(App.IsElevated);
ShellPage.SetIsUserAnAdmin(App.IsUserAnAdmin);
shellPage.Refresh();
//shellPage.Refresh();
}
public void NavigateToSection(Type type)
{
Activate();
ShellPage.Navigate(type);
}
}
}