Skip to content

Task/UI usability tweaks #1314

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

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,4 @@ build/*.rpm
build/*.AppImage
SourceGit.app/
build.command
src/Properties/launchSettings.json
9 changes: 7 additions & 2 deletions src/App.axaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,13 @@ public static void ShowWindow(object data, bool showAsDialog)
{
if (data is Views.ChromelessWindow window)
{
if (showAsDialog && Current?.ApplicationLifetime is IClassicDesktopStyleApplicationLifetime { MainWindow: { } owner })
window.ShowDialog(owner);
if (Current?.ApplicationLifetime is IClassicDesktopStyleApplicationLifetime { MainWindow: { } owner })
{
if (showAsDialog)
window.ShowDialog(owner);
else
window.Show(owner);
}
else
window.Show();

Expand Down
7 changes: 6 additions & 1 deletion src/Views/About.axaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
Title="{DynamicResource Text.About}"
Width="520" Height="230"
CanResize="False"
WindowStartupLocation="CenterScreen">
WindowStartupLocation="CenterOwner">
<Grid RowDefinitions="Auto,*">
<!-- TitleBar -->
<Grid Grid.Row="0" Height="28" IsVisible="{Binding !#ThisControl.UseSystemWindowFrame}">
Expand Down Expand Up @@ -67,4 +67,9 @@
</StackPanel>
</Grid>
</Grid>

<Window.KeyBindings>
<KeyBinding Gesture="Escape" Command="{Binding #ThisControl.Close}"/>
</Window.KeyBindings>

</v:ChromelessWindow>
2 changes: 2 additions & 0 deletions src/Views/ConfirmEmptyCommit.axaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
Title="{DynamicResource Text.Warn}"
SizeToContent="WidthAndHeight"
CanResize="False"
ShowInTaskbar="False"
WindowStartupLocation="CenterOwner">
<Grid RowDefinitions="Auto,Auto,Auto">
<!-- TitleBar -->
Expand Down Expand Up @@ -64,6 +65,7 @@
Height="30"
Margin="4,0"
Click="CloseWindow"
IsCancel="True"
Content="{DynamicResource Text.Cancel}"
HorizontalContentAlignment="Center"
VerticalContentAlignment="Center"/>
Expand Down