Přidání nového projektu - pokus o explorer
This commit is contained in:
1 parent
b0b0b3ee34
commit
d06a9f332b
48 files changed
+1429
No files matched your search
@@ -0,0 +1,34 @@
|
||||
using Microsoft.UI.Xaml;
|
||||
using TitleBar = Microsoft.UI.Xaml.Controls.TitleBar;
|
||||
using winui_learning_2.Services;
|
||||
using winui_learning_2.Views;
|
||||
|
||||
namespace winui_learning_2;
|
||||
|
||||
public sealed partial class MainWindow : Window
|
||||
{
|
||||
public MainWindow()
|
||||
{
|
||||
InitializeComponent();
|
||||
ExtendsContentIntoTitleBar = true;
|
||||
SetTitleBar(AppTitleBar);
|
||||
|
||||
if (AuthSession.IsAuthenticated)
|
||||
{
|
||||
rootFrame.Navigate(typeof(HomePage));
|
||||
}
|
||||
else
|
||||
{
|
||||
rootFrame.Navigate(typeof(LoginPage));
|
||||
}
|
||||
}
|
||||
|
||||
private void AppTitleBar_BackRequested(TitleBar titleBar, object args)
|
||||
{
|
||||
if (rootFrame.CanGoBack)
|
||||
{
|
||||
rootFrame.GoBack();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user