aboutsummaryrefslogtreecommitdiff
path: root/src/Ryujinx.Ava/UI/Views/Input/RumbleInputView.axaml
diff options
context:
space:
mode:
authorAhmad Tantowi <ahmadtantowi@outlook.com>2023-10-20 21:02:12 +0700
committerGitHub <noreply@github.com>2023-10-20 16:02:12 +0200
commitb4bb22ba06f89168c948e6001c51972575ca968b (patch)
tree44e71b5fe08adcac5a04f89095be3f7ca341b965 /src/Ryujinx.Ava/UI/Views/Input/RumbleInputView.axaml
parent6fdf7748455b2b71f99885239f8dc31390de2687 (diff)
Avalonia: Make slider scrollable with mouse wheel (#5760)
* Add scrollable custom control based on TickFrequency * Use custom slider to update value when pointer wheel scrolled * Remove extra xaml file * Address formatting issues * Only scroll one element at a time * Add OnPointerWheelChanged event to VolumeStatus button Co-authored-by: Ahmad Tantowi <ahmadtantowi@outlook.com> --------- Co-authored-by: TSR Berry <20988865+TSRBerry@users.noreply.github.com>
Diffstat (limited to 'src/Ryujinx.Ava/UI/Views/Input/RumbleInputView.axaml')
-rw-r--r--src/Ryujinx.Ava/UI/Views/Input/RumbleInputView.axaml7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/Ryujinx.Ava/UI/Views/Input/RumbleInputView.axaml b/src/Ryujinx.Ava/UI/Views/Input/RumbleInputView.axaml
index f633c0ed..5b7087a4 100644
--- a/src/Ryujinx.Ava/UI/Views/Input/RumbleInputView.axaml
+++ b/src/Ryujinx.Ava/UI/Views/Input/RumbleInputView.axaml
@@ -1,6 +1,7 @@
<UserControl
xmlns="https://github.com/avaloniaui"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:controls="clr-namespace:Ryujinx.Ava.UI.Controls"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:locale="clr-namespace:Ryujinx.Ava.Common.Locale"
@@ -21,7 +22,7 @@
TextWrapping="WrapWithOverflow"
HorizontalAlignment="Center"
Text="{locale:Locale ControllerSettingsRumbleStrongMultiplier}" />
- <Slider
+ <controls:SliderScroll
Margin="0,-5,0,-5"
Width="200"
TickFrequency="0.01"
@@ -41,7 +42,7 @@
TextWrapping="WrapWithOverflow"
HorizontalAlignment="Center"
Text="{locale:Locale ControllerSettingsRumbleWeakMultiplier}" />
- <Slider
+ <controls:SliderScroll
Margin="0,-5,0,-5"
Width="200"
MaxWidth="200"
@@ -58,4 +59,4 @@
</StackPanel>
</StackPanel>
</Grid>
-</UserControl> \ No newline at end of file
+</UserControl>