|
@@ -12,6 +12,7 @@ using System.Windows.Media;
|
|
|
using System.Windows.Media.Imaging;
|
|
|
using System.Windows.Navigation;
|
|
|
using System.Windows.Shapes;
|
|
|
+using Тураев_БД_11._20._1.Pages;
|
|
|
|
|
|
namespace Тураев_БД_11._20._1
|
|
|
{
|
|
@@ -25,5 +26,25 @@ namespace Тураев_БД_11._20._1
|
|
|
InitializeComponent();
|
|
|
///izmenenie
|
|
|
}
|
|
|
+
|
|
|
+ private void MainFrame_OnNavigated(object sender, NavigationEventArgs e)
|
|
|
+ {
|
|
|
+ if (!(e.Content is Page page)) return;
|
|
|
+ this.Title = $"LESSON - {page.Title}";
|
|
|
+
|
|
|
+ if (page is AuthPage)
|
|
|
+ {
|
|
|
+ ButtonBack.Visibility = Visibility.Hidden;
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ ButtonBack.Visibility = Visibility.Visible;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ private void ButtonBack_Click(object sender, RoutedEventArgs e)
|
|
|
+ {
|
|
|
+ if (MainFrame.CanGoBack) MainFrame.GoBack();
|
|
|
+ }
|
|
|
}
|
|
|
}
|