From 41790aa7434a5e6d132fad2e24844d450378205b Mon Sep 17 00:00:00 2001 From: MutantAura <44103205+MutantAura@users.noreply.github.com> Date: Mon, 19 Sep 2022 20:04:22 +0100 Subject: [PATCH] Avalonia - Misc changes to UX (#3643) * Change navbar from compact to default and force text overflow globally * Fix settings window * Fix right stick control alignment * Initialize value and add logging for SDL IDs * Fix alignment of setting text and improve borders * Clean up padding and size of buttons on controller settings * Fix right side trigger alignment and correct styling * Revert axaml alignment * Fix alignment of volume widget * Fix timezone autocompletebox dropdown height * MainWindow: Line up volume status bar item * Remove margins and add padding to volume widget * Make volume text localizable. Co-authored-by: merry --- Ryujinx.Ava/AppHost.cs | 2 +- Ryujinx.Ava/Assets/Locales/en_US.json | 3 +- Ryujinx.Ava/Assets/Styles/Styles.xaml | 14 ++ .../Ui/Models/StatusUpdatedEventArgs.cs | 6 +- .../ViewModels/ControllerSettingsViewModel.cs | 24 +++- .../Ui/ViewModels/MainWindowViewModel.cs | 8 +- .../Ui/Windows/ControllerSettingsWindow.axaml | 33 ++--- Ryujinx.Ava/Ui/Windows/MainWindow.axaml | 8 +- Ryujinx.Ava/Ui/Windows/MainWindow.axaml.cs | 1 + Ryujinx.Ava/Ui/Windows/SettingsWindow.axaml | 120 ++++++++++-------- 10 files changed, 133 insertions(+), 86 deletions(-) diff --git a/Ryujinx.Ava/AppHost.cs b/Ryujinx.Ava/AppHost.cs index 7cf5934a..320efeb5 100644 --- a/Ryujinx.Ava/AppHost.cs +++ b/Ryujinx.Ava/AppHost.cs @@ -879,7 +879,7 @@ namespace Ryujinx.Ava StatusUpdatedEvent?.Invoke(this, new StatusUpdatedEventArgs( Device.EnableDeviceVsync, - Device.GetVolume(), + LocaleManager.Instance["VolumeShort"] + $": {(int)(Device.GetVolume() * 100)}%", Renderer.IsVulkan ? "Vulkan" : "OpenGL", dockedMode, ConfigurationState.Instance.Graphics.AspectRatio.Value.ToText(), diff --git a/Ryujinx.Ava/Assets/Locales/en_US.json b/Ryujinx.Ava/Assets/Locales/en_US.json index 350e2063..a6641a02 100644 --- a/Ryujinx.Ava/Assets/Locales/en_US.json +++ b/Ryujinx.Ava/Assets/Locales/en_US.json @@ -588,5 +588,6 @@ "SettingsTabGraphicsPreferredGpuTooltip": "Select the graphics card that will be used with the Vulkan graphics backend.\n\nDoes not affect the GPU that OpenGL will use.\n\nSet to the GPU flagged as \"dGPU\" if unsure. If there isn't one, leave untouched.", "SettingsAppRequiredRestartMessage": "Ryujinx Restart Required", "SettingsGpuBackendRestartMessage": "Graphics Backend or Gpu settings have been modified. This will require a restart to be applied", - "SettingsGpuBackendRestartSubMessage": "Do you want to restart now?" + "SettingsGpuBackendRestartSubMessage": "Do you want to restart now?", + "VolumeShort": "Vol" } diff --git a/Ryujinx.Ava/Assets/Styles/Styles.xaml b/Ryujinx.Ava/Assets/Styles/Styles.xaml index c93640ae..8b09bafd 100644 --- a/Ryujinx.Ava/Assets/Styles/Styles.xaml +++ b/Ryujinx.Ava/Assets/Styles/Styles.xaml @@ -54,6 +54,12 @@ + @@ -193,6 +199,14 @@ + + +