Always-on-Top mode implemented (#579)
This commit is contained in:
committed by
Pepe Rivera
parent
af8322617f
commit
796d171960
@@ -32,6 +32,9 @@
|
||||
<Style x:Key="NavViewItemStyle" TargetType="muxc:NavigationViewItem">
|
||||
<Setter Property="KeyTipPlacementMode" Value="Right"/>
|
||||
</Style>
|
||||
|
||||
<converters:BooleanToVisibilityNegationConverter x:Key="BooleanToVisibilityNegationConverter"/>
|
||||
<converters:BooleanNegationConverter x:Key="BooleanNegationConverter"/>
|
||||
</Page.Resources>
|
||||
|
||||
<Grid>
|
||||
@@ -83,8 +86,21 @@
|
||||
Command="{x:Bind Model.PasteCommand}"/>
|
||||
</StackPanel>
|
||||
|
||||
<local:TitleBar x:Name="CustomTitleBar" Grid.Row="0"/>
|
||||
|
||||
<local:TitleBar x:Name="CustomTitleBar" Grid.Row="0"
|
||||
ApplicationViewModel="{x:Bind Model}"/>
|
||||
|
||||
<Grid Grid.Row="1">
|
||||
<Border x:Name="CalcHolder">
|
||||
<!-- PLACEHOLDER!!!! This is where the calculator goes when it is delay loaded -->
|
||||
</Border>
|
||||
<Border x:Name="DateCalcHolder">
|
||||
<!-- PLACEHOLDER!!!! This is where the date calculator goes when it is delay loaded -->
|
||||
</Border>
|
||||
<Border x:Name="ConverterHolder">
|
||||
<!-- PLACEHOLDER!!!! This is where the converter goes when it is delay loaded -->
|
||||
</Border>
|
||||
</Grid>
|
||||
|
||||
<muxc:NavigationView x:Name="NavView"
|
||||
x:Uid="NavView"
|
||||
Grid.Row="1"
|
||||
@@ -92,6 +108,8 @@
|
||||
DataContext="{x:Bind Model}"
|
||||
ExpandedModeThresholdWidth="Infinity"
|
||||
IsBackButtonVisible="Collapsed"
|
||||
IsPaneToggleButtonVisible="{x:Bind Model.IsAlwaysOnTop, Converter={StaticResource BooleanNegationConverter}, Mode=OneWay}"
|
||||
IsEnabled="{x:Bind Model.IsAlwaysOnTop, Converter={StaticResource BooleanNegationConverter}, Mode=OneWay}"
|
||||
IsSettingsVisible="False"
|
||||
Loaded="OnNavLoaded"
|
||||
MenuItemsSource="{x:Bind CreateUIElementsForCategories(Model.Categories), Mode=OneWay}"
|
||||
@@ -103,6 +121,7 @@
|
||||
ItemInvoked="OnNavItemInvoked"
|
||||
TabIndex="1"
|
||||
UseSystemFocusVisuals="True">
|
||||
|
||||
<muxc:NavigationView.PaneFooter>
|
||||
<StackPanel HorizontalAlignment="Stretch" Orientation="Vertical">
|
||||
<muxc:NavigationViewList x:Name="NavFooter"
|
||||
@@ -135,24 +154,31 @@
|
||||
</muxc:NavigationViewList>
|
||||
</StackPanel>
|
||||
</muxc:NavigationView.PaneFooter>
|
||||
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="Auto"></ColumnDefinition>
|
||||
<ColumnDefinition Width="Auto"></ColumnDefinition>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock x:Name="Header"
|
||||
Margin="52,6,12,0"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Top"
|
||||
Visibility="{x:Bind Model.IsAlwaysOnTop, Converter={StaticResource BooleanToVisibilityNegationConverter}, Mode=OneWay}"
|
||||
Style="{StaticResource SubtitleTextBlockStyle}"
|
||||
Text="{x:Bind Model.CategoryName, Mode=OneWay}"/>
|
||||
|
||||
<Border x:Name="CalcHolder">
|
||||
<!-- PLACEHOLDER!!!! This is where the calculator goes when it is delay loaded -->
|
||||
</Border>
|
||||
<Border x:Name="DateCalcHolder">
|
||||
<!-- PLACEHOLDER!!!! This is where the date calculator goes when it is delay loaded -->
|
||||
</Border>
|
||||
<Border x:Name="ConverterHolder">
|
||||
<!-- PLACEHOLDER!!!! This is where the converter goes when it is delay loaded -->
|
||||
</Border>
|
||||
Text="{x:Bind Model.CategoryName, Mode=OneWay}"
|
||||
Grid.Column="0"/>
|
||||
<Button x:Name="NormalAlwaysOnTopButton"
|
||||
x:Uid="EnterAlwaysOnTopButton"
|
||||
FontFamily="{StaticResource CalculatorFontFamily}"
|
||||
Style="{StaticResource SquareIconButtonStyle}"
|
||||
Content=""
|
||||
Click="AlwaysOnTopButtonClick"
|
||||
VerticalAlignment="Top"
|
||||
HorizontalContentAlignment="Center"
|
||||
Background="Transparent"
|
||||
Visibility="{x:Bind Model.DisplayNormalAlwaysOnTopOption, Mode=OneWay}"
|
||||
AutomationProperties.AutomationId="NormalAlwaysOnTopButton"
|
||||
Grid.Column="1"/>
|
||||
</Grid>
|
||||
</muxc:NavigationView>
|
||||
</Grid>
|
||||
|
||||
Reference in New Issue
Block a user