Skip to content

Commit

Permalink
Allow opening entries in folder view by pressing Enter.
Browse files Browse the repository at this point in the history
  • Loading branch information
jp2masa committed Sep 16, 2024
1 parent 8d5dcae commit e1be528
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/Movere/Views/FileExplorerFolderView.axaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:i="clr-namespace:Avalonia.Xaml.Interactivity;assembly=Avalonia.Xaml.Interactivity"
xmlns:ia="clr-namespace:Avalonia.Xaml.Interactions.Core;assembly=Avalonia.Xaml.Interactions"
xmlns:iac="clr-namespace:Avalonia.Xaml.Interactions.Custom;assembly=Avalonia.Xaml.Interactions.Custom"
xmlns:b="clr-namespace:Movere.Behaviors"
xmlns:c="clr-namespace:Movere.Controls"
xmlns:conv="clr-namespace:Movere.Converters"
Expand Down Expand Up @@ -46,6 +47,13 @@
<ia:InvokeCommandAction Command="{Binding #root.ViewModel.OpenItemCommand}"
CommandParameter="{Binding}" />
</ia:EventTriggerBehavior>
<iac:KeyDownTrigger
EventRoutingStrategy="Bubble"
Key="Enter">
<ia:InvokeCommandAction
Command="{Binding #root.ViewModel.OpenItemCommand}"
CommandParameter="{Binding}" />
</iac:KeyDownTrigger>
</i:BehaviorCollection>
</b:BehaviorFactoryControl>
</b:BehaviorCollectionTemplate>
Expand Down

0 comments on commit e1be528

Please sign in to comment.