Skip to content

Commit

Permalink
Pressing ENTER ticks the box, and pressing ENTER again executes the c…
Browse files Browse the repository at this point in the history
…ontinue button
  • Loading branch information
wieslawsoltes committed May 7, 2024
1 parent 763e1a6 commit 8a16824
Showing 1 changed file with 11 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@
EnableBack="{Binding EnableBack}"
EnableNext="True" NextContent="Continue" FocusNext="True"
ScrollViewer.HorizontalScrollBarVisibility="Auto">
<Interaction.Behaviors>
<ExecuteCommandOnKeyDownBehavior KeyGesture="Enter" Command="{Binding NextCommand}" />
</Interaction.Behaviors>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="*" />
Expand Down Expand Up @@ -93,9 +96,16 @@
Text="{Binding Passphrase}" />
</StackPanel>

<CheckBox HorizontalAlignment="Center"
<CheckBox x:Name="CheckBox"
HorizontalAlignment="Center"
IsChecked="{Binding IsConfirmed}"
Grid.Row="7">
<Interaction.Behaviors>
<FocusOnAttachedBehavior />
<DataTriggerBehavior Binding="{Binding #CheckBox.IsChecked}" Value="True">
<FocusNextControlAction />
</DataTriggerBehavior>
</Interaction.Behaviors>
<CheckBox.Content>
<StackPanel Orientation="Horizontal">
<TextBlock Text="I have written down the 12 words" />
Expand Down

0 comments on commit 8a16824

Please sign in to comment.