Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Moving to a Nested NavView #8

Draft
wants to merge 13 commits into
base: main
Choose a base branch
from
40 changes: 38 additions & 2 deletions AIDevGallery/MainWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
IsBackButtonVisible="Collapsed"
IsPaneToggleButtonVisible="False"
IsSettingsVisible="False"
ItemInvoked="NavView_ItemInvoked"
SelectionFollowsFocus="Disabled"
Style="{StaticResource MainNavigationViewStyle}">
<!--<NavigationView.Resources>
<SolidColorBrush x:Key="NavigationViewContentBackground" Color="Transparent" />
Expand All @@ -93,10 +93,12 @@
Tag="Home" />
<NavigationViewItem
Content="Samples"
x:Name="SamplesNavItem"
Icon="{ui:FontIcon Glyph=&#xE754;}"
Tag="Samples" />
<NavigationViewItem
Content="Models"
x:Name="ModelsNavItem"
Icon="{ui:FontIcon Glyph=&#xF158;}"
Tag="Models" />
<!--<NavigationViewItem
Expand All @@ -119,7 +121,41 @@
Tag="Settings" />
</NavigationView.FooterMenuItems>
<NavigationView.Content>
<Frame x:Name="NavFrame" Navigating="NavFrame_Navigating" />
<NavigationView
x:Name="InnerNavView"
CompactModeThresholdWidth="0"
ExpandedModeThresholdWidth="0"
IsBackButtonVisible="Collapsed"
IsPaneOpen="True"
IsPaneToggleButtonVisible="False"
SelectionChanged="InnerNavViewSelectionChanged"
IsPaneVisible="True"
IsSettingsVisible="False"
OpenPaneLength="0">
<NavigationView.Resources>
<Thickness x:Key="NavigationViewContentGridBorderThickness">1,0,0,0</Thickness>
<CornerRadius x:Key="NavigationViewContentGridCornerRadius">0,0,0,0</CornerRadius>
</NavigationView.Resources>
<NavigationView.PaneHeader>
<TextBlock
x:Name="NavViewInnerHeader"
Margin="16,12,0,12"
Style="{StaticResource SubtitleTextBlockStyle}" />
</NavigationView.PaneHeader>
<NavigationView.Content>
<Frame x:Name="NavFrame" Navigating="NavFrame_Navigating" />
</NavigationView.Content>
<NavigationView.PaneFooter>
<StackPanel Orientation="Vertical" x:Name="ModelsFooter" Visibility="Collapsed">
<HyperlinkButton
Grid.Row="1"
Margin="0,4,0,0"
HorizontalAlignment="Right"
Click="ManageModelsClicked"
Content="Manage models" />
</StackPanel>
</NavigationView.PaneFooter>
</NavigationView>
</NavigationView.Content>
</NavigationView>
<controls:TitleBar
Expand Down
Loading