mirror of
https://github.com/BililiveRecorder/BililiveRecorder.git
synced 2024-11-16 11:42:22 +08:00
86 lines
4.9 KiB
XML
86 lines
4.9 KiB
XML
<UserControl
|
|
x:Class="BililiveRecorder.WPF.Pages.RootPage"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
xmlns:ui="http://schemas.modernwpf.com/2019"
|
|
xmlns:local="clr-namespace:BililiveRecorder.WPF.Pages"
|
|
xmlns:wpf="clr-namespace:BililiveRecorder.WPF"
|
|
xmlns:controls="clr-namespace:BililiveRecorder.WPF.Controls"
|
|
xmlns:models="clr-namespace:BililiveRecorder.WPF.Models"
|
|
mc:Ignorable="d" d:DesignWidth="900" d:DesignHeight="600"
|
|
d:DataContext="{d:DesignInstance Type=models:RootModel,IsDesignTimeCreatable=True}"
|
|
Background="{DynamicResource SystemControlPageBackgroundAltHighBrush}">
|
|
<UserControl.Resources>
|
|
<Style x:Key="CascadeDataContextFrame" TargetType="{x:Type ui:Frame}">
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type ui:Frame}">
|
|
<Border
|
|
BorderBrush="{TemplateBinding BorderBrush}"
|
|
BorderThickness="{TemplateBinding BorderThickness}"
|
|
Background="{TemplateBinding Background}"
|
|
ClipToBounds="True"
|
|
Padding="{TemplateBinding Padding}">
|
|
<Grid>
|
|
<ContentPresenter
|
|
x:Name="FirstContentPresenter"
|
|
Content="{x:Null}"
|
|
DataContext="{TemplateBinding DataContext}"
|
|
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
|
|
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
|
|
<ContentPresenter
|
|
x:Name="SecondContentPresenter"
|
|
Content="{x:Null}"
|
|
DataContext="{TemplateBinding DataContext}"
|
|
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
|
|
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
|
|
</Grid>
|
|
</Border>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
</UserControl.Resources>
|
|
<Grid>
|
|
<controls:TaskbarIconControl DataContext="{Binding}" d:IsHidden="True"/>
|
|
<ui:NavigationView IsBackEnabled="False" IsBackButtonVisible="Collapsed"
|
|
IsPaneOpen="False" OpenPaneLength="150"
|
|
IsSettingsVisible="False"
|
|
SelectionChanged="NavigationView_SelectionChanged"
|
|
>
|
|
<ui:NavigationView.MenuItems>
|
|
<ui:NavigationViewItem Content="公告" Tag="AnnouncementPage" IsSelected="True">
|
|
<ui:NavigationViewItem.Icon>
|
|
<ui:PathIcon Style="{StaticResource PathIconDataBullhornOutline}"/>
|
|
</ui:NavigationViewItem.Icon>
|
|
</ui:NavigationViewItem>
|
|
<ui:NavigationViewItem Content="房间列表" Tag="RoomListPage" x:Name="RoomListPageNavigationViewItem">
|
|
<ui:NavigationViewItem.Icon>
|
|
<ui:PathIcon Style="{StaticResource PathIconDataHomeOutline}"/>
|
|
</ui:NavigationViewItem.Icon>
|
|
</ui:NavigationViewItem>
|
|
</ui:NavigationView.MenuItems>
|
|
<ui:NavigationView.FooterMenuItems>
|
|
<ui:NavigationViewItem Content="高级设置" Tag="AdvancedSettingsPage" x:Name="AdvancedSettingsPageItem">
|
|
<ui:NavigationViewItem.Icon>
|
|
<ui:PathIcon Style="{StaticResource PathIconDataCogs}"/>
|
|
</ui:NavigationViewItem.Icon>
|
|
</ui:NavigationViewItem>
|
|
<ui:NavigationViewItem Content="日志" Tag="LogPage">
|
|
<ui:NavigationViewItem.Icon>
|
|
<ui:PathIcon Style="{StaticResource PathIconDataPaperRollOutline}"/>
|
|
</ui:NavigationViewItem.Icon>
|
|
</ui:NavigationViewItem>
|
|
<ui:NavigationViewItem Content="设置" Tag="SettingsPage" MouseRightButtonUp="NavigationViewItem_MouseRightButtonUp">
|
|
<ui:NavigationViewItem.Icon>
|
|
<ui:PathIcon Style="{StaticResource PathIconDataCogOutline}"/>
|
|
</ui:NavigationViewItem.Icon>
|
|
</ui:NavigationViewItem>
|
|
</ui:NavigationView.FooterMenuItems>
|
|
<ui:Frame x:Name="MainFrame" Style="{DynamicResource CascadeDataContextFrame}" Navigated="MainFrame_Navigated" />
|
|
</ui:NavigationView>
|
|
</Grid>
|
|
</UserControl>
|