Apply suggestions from code review
Co-authored-by: Ac_K <Acoustik666@gmail.com>
This commit is contained in:
parent
1c9ae7d5d0
commit
4ca6acdd4a
5 changed files with 16 additions and 15 deletions
|
@ -504,7 +504,7 @@ namespace Ryujinx.Ava.UI.Models.Input
|
||||||
ButtonMinus = ButtonMinus,
|
ButtonMinus = ButtonMinus,
|
||||||
ButtonSl = LeftButtonSl,
|
ButtonSl = LeftButtonSl,
|
||||||
ButtonSr = LeftButtonSr,
|
ButtonSr = LeftButtonSr,
|
||||||
ButtonZl = ButtonZl
|
ButtonZl = ButtonZl,
|
||||||
},
|
},
|
||||||
RightJoycon = new RightJoyconCommonConfig<GamepadInputId>
|
RightJoycon = new RightJoyconCommonConfig<GamepadInputId>
|
||||||
{
|
{
|
||||||
|
@ -516,7 +516,7 @@ namespace Ryujinx.Ava.UI.Models.Input
|
||||||
ButtonSl = RightButtonSl,
|
ButtonSl = RightButtonSl,
|
||||||
ButtonSr = RightButtonSr,
|
ButtonSr = RightButtonSr,
|
||||||
ButtonR = ButtonR,
|
ButtonR = ButtonR,
|
||||||
ButtonZr = ButtonZr
|
ButtonZr = ButtonZr,
|
||||||
},
|
},
|
||||||
LeftJoyconStick = new JoyconConfigControllerStick<GamepadInputId, StickInputId>
|
LeftJoyconStick = new JoyconConfigControllerStick<GamepadInputId, StickInputId>
|
||||||
{
|
{
|
||||||
|
@ -524,7 +524,7 @@ namespace Ryujinx.Ava.UI.Models.Input
|
||||||
InvertStickX = LeftInvertStickX,
|
InvertStickX = LeftInvertStickX,
|
||||||
InvertStickY = LeftInvertStickY,
|
InvertStickY = LeftInvertStickY,
|
||||||
Rotate90CW = LeftRotate90,
|
Rotate90CW = LeftRotate90,
|
||||||
StickButton = LeftStickButton
|
StickButton = LeftStickButton,
|
||||||
},
|
},
|
||||||
RightJoyconStick = new JoyconConfigControllerStick<GamepadInputId, StickInputId>
|
RightJoyconStick = new JoyconConfigControllerStick<GamepadInputId, StickInputId>
|
||||||
{
|
{
|
||||||
|
@ -532,20 +532,20 @@ namespace Ryujinx.Ava.UI.Models.Input
|
||||||
InvertStickX = RightInvertStickX,
|
InvertStickX = RightInvertStickX,
|
||||||
InvertStickY = RightInvertStickY,
|
InvertStickY = RightInvertStickY,
|
||||||
Rotate90CW = RightRotate90,
|
Rotate90CW = RightRotate90,
|
||||||
StickButton = RightStickButton
|
StickButton = RightStickButton,
|
||||||
},
|
},
|
||||||
Rumble = new RumbleConfigController
|
Rumble = new RumbleConfigController
|
||||||
{
|
{
|
||||||
EnableRumble = EnableRumble,
|
EnableRumble = EnableRumble,
|
||||||
WeakRumble = WeakRumble,
|
WeakRumble = WeakRumble,
|
||||||
StrongRumble = StrongRumble
|
StrongRumble = StrongRumble,
|
||||||
},
|
},
|
||||||
Version = InputConfig.CurrentVersion,
|
Version = InputConfig.CurrentVersion,
|
||||||
DeadzoneLeft = DeadzoneLeft,
|
DeadzoneLeft = DeadzoneLeft,
|
||||||
DeadzoneRight = DeadzoneRight,
|
DeadzoneRight = DeadzoneRight,
|
||||||
RangeLeft = RangeLeft,
|
RangeLeft = RangeLeft,
|
||||||
RangeRight = RangeRight,
|
RangeRight = RangeRight,
|
||||||
TriggerThreshold = TriggerThreshold
|
TriggerThreshold = TriggerThreshold,
|
||||||
};
|
};
|
||||||
|
|
||||||
if (EnableCemuHookMotion)
|
if (EnableCemuHookMotion)
|
||||||
|
@ -560,7 +560,7 @@ namespace Ryujinx.Ava.UI.Models.Input
|
||||||
DsuServerPort = DsuServerPort,
|
DsuServerPort = DsuServerPort,
|
||||||
Slot = Slot,
|
Slot = Slot,
|
||||||
AltSlot = AltSlot,
|
AltSlot = AltSlot,
|
||||||
MirrorInput = MirrorInput
|
MirrorInput = MirrorInput,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -570,7 +570,7 @@ namespace Ryujinx.Ava.UI.Models.Input
|
||||||
EnableMotion = EnableMotion,
|
EnableMotion = EnableMotion,
|
||||||
MotionBackend = MotionInputBackendType.GamepadDriver,
|
MotionBackend = MotionInputBackendType.GamepadDriver,
|
||||||
GyroDeadzone = GyroDeadzone,
|
GyroDeadzone = GyroDeadzone,
|
||||||
Sensitivity = Sensitivity
|
Sensitivity = Sensitivity,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -132,7 +132,7 @@ namespace Ryujinx.Ava.UI.Models.Input
|
||||||
ResScaleUp = ResScaleUp,
|
ResScaleUp = ResScaleUp,
|
||||||
ResScaleDown = ResScaleDown,
|
ResScaleDown = ResScaleDown,
|
||||||
VolumeUp = VolumeUp,
|
VolumeUp = VolumeUp,
|
||||||
VolumeDown = VolumeDown
|
VolumeDown = VolumeDown,
|
||||||
};
|
};
|
||||||
|
|
||||||
return config;
|
return config;
|
||||||
|
|
|
@ -383,7 +383,7 @@ namespace Ryujinx.Ava.UI.Models.Input
|
||||||
ButtonMinus = ButtonMinus,
|
ButtonMinus = ButtonMinus,
|
||||||
ButtonZl = ButtonZl,
|
ButtonZl = ButtonZl,
|
||||||
ButtonSl = LeftButtonSl,
|
ButtonSl = LeftButtonSl,
|
||||||
ButtonSr = LeftButtonSr
|
ButtonSr = LeftButtonSr,
|
||||||
},
|
},
|
||||||
RightJoycon = new RightJoyconCommonConfig<Key>
|
RightJoycon = new RightJoyconCommonConfig<Key>
|
||||||
{
|
{
|
||||||
|
@ -395,7 +395,7 @@ namespace Ryujinx.Ava.UI.Models.Input
|
||||||
ButtonSl = RightButtonSl,
|
ButtonSl = RightButtonSl,
|
||||||
ButtonSr = RightButtonSr,
|
ButtonSr = RightButtonSr,
|
||||||
ButtonR = ButtonR,
|
ButtonR = ButtonR,
|
||||||
ButtonZr = ButtonZr
|
ButtonZr = ButtonZr,
|
||||||
},
|
},
|
||||||
LeftJoyconStick = new JoyconConfigKeyboardStick<Key>
|
LeftJoyconStick = new JoyconConfigKeyboardStick<Key>
|
||||||
{
|
{
|
||||||
|
@ -403,7 +403,7 @@ namespace Ryujinx.Ava.UI.Models.Input
|
||||||
StickDown = LeftStickDown,
|
StickDown = LeftStickDown,
|
||||||
StickRight = LeftStickRight,
|
StickRight = LeftStickRight,
|
||||||
StickLeft = LeftStickLeft,
|
StickLeft = LeftStickLeft,
|
||||||
StickButton = LeftStickButton
|
StickButton = LeftStickButton,
|
||||||
},
|
},
|
||||||
RightJoyconStick = new JoyconConfigKeyboardStick<Key>
|
RightJoyconStick = new JoyconConfigKeyboardStick<Key>
|
||||||
{
|
{
|
||||||
|
@ -411,9 +411,9 @@ namespace Ryujinx.Ava.UI.Models.Input
|
||||||
StickDown = RightStickDown,
|
StickDown = RightStickDown,
|
||||||
StickLeft = RightStickLeft,
|
StickLeft = RightStickLeft,
|
||||||
StickRight = RightStickRight,
|
StickRight = RightStickRight,
|
||||||
StickButton = RightStickButton
|
StickButton = RightStickButton,
|
||||||
},
|
},
|
||||||
Version = InputConfig.CurrentVersion
|
Version = InputConfig.CurrentVersion,
|
||||||
};
|
};
|
||||||
|
|
||||||
return config;
|
return config;
|
||||||
|
|
|
@ -54,7 +54,7 @@ namespace Ryujinx.Ava.UI.Views.Input
|
||||||
{
|
{
|
||||||
_currentAssigner = new ButtonKeyAssigner(button);
|
_currentAssigner = new ButtonKeyAssigner(button);
|
||||||
|
|
||||||
this.Focus(NavigationMethod.Pointer);
|
Focus(NavigationMethod.Pointer);
|
||||||
|
|
||||||
PointerPressed += MouseClick;
|
PointerPressed += MouseClick;
|
||||||
|
|
||||||
|
|
|
@ -28,6 +28,7 @@ namespace Ryujinx.Ava.UI.Views.Settings
|
||||||
button.IsCheckedChanged += Button_IsCheckedChanged;
|
button.IsCheckedChanged += Button_IsCheckedChanged;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
_avaloniaKeyboardDriver = new AvaloniaKeyboardDriver(this);
|
_avaloniaKeyboardDriver = new AvaloniaKeyboardDriver(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue