Changed behavior to accept keyboard overrides, added keyboard mouse state validator and indirect rules to allow keyboard and mouse navigation

This commit is contained in:
Ano-sys
2026-04-03 02:22:57 +02:00
parent 162df64596
commit d25e8238f2
4 changed files with 213 additions and 75 deletions
+10 -5
View File
@@ -64,6 +64,8 @@
Background="Transparent"
Foreground="#EDEDED"
Margin="5,0,0,0"
IsTabStop="False"
Focusable="False"
>
<!--
<MenuItem Header="_File">
@@ -71,8 +73,8 @@
<MenuItem Header="_Close" Command="{Binding CloseDirectory}"/>
</MenuItem>
-->
<MenuItem Header="_Open Library" IsVisible="{Binding !PhotosLoaded}" Command="{Binding OpenDirectory}"/>
<MenuItem Header="_Close Library" IsVisible="{Binding PhotosLoaded}" Command="{Binding CloseDirectory}"/>
<MenuItem Header="_Open Library" Focusable="False" IsVisible="{Binding !PhotosLoaded}" Command="{Binding OpenDirectory}"/>
<MenuItem Header="_Close Library" Focusable="False" IsVisible="{Binding PhotosLoaded}" Command="{Binding CloseDirectory}"/>
</Menu>
</DockPanel>
</Border>
@@ -114,11 +116,13 @@
Grid.RowSpan="2"
IsVisible="{Binding PhotosLoaded}">
<Border Padding="72,88,72,48">
<ItemsRepeater ItemsSource="{Binding Photos}"
<ItemsRepeater x:Name="Repeater"
ItemsSource="{Binding Photos}"
HorizontalAlignment="Stretch"
VerticalAlignment="Stretch"
ClipToBounds="False"
IsTabStop="True">
IsTabStop="True"
>
<ItemsRepeater.Layout>
<UniformGridLayout MinItemWidth="220"
MinItemHeight="290"
@@ -136,7 +140,8 @@
BoxShadow="0 10 24 0 #30000000"
anim:CardHoverEffectBehavior.IsEnabled="True"
anim:CardHoverEffectBehavior.MaxRotationAngle="2.5"
anim:CardHoverEffectBehavior.ScaleFactor="1.08">
anim:CardHoverEffectBehavior.ScaleFactor="1.08"
>
<StackPanel Orientation="Vertical"
Spacing="10">
<i:Interaction.Behaviors>