-
Notifications
You must be signed in to change notification settings - Fork 528
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
Adds gamepad exit hotkeys (plus and minus) to the input section #504
base: master
Are you sure you want to change the base?
Conversation
…s the settings were reset to default
…hen changing parameters
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks fine, apart from the project coding style violations & Spetial
.
private static bool hotButtonMinus = false; | ||
private static bool HotExit = false; | ||
|
||
public bool spetialExit() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Improper casing + misspelling
bool ignoreControllerApplet) | ||
: base(inputManager, glLogLevel, aspectRatio, enableMouse, hideCursorMode, ignoreControllerApplet) { } | ||
bool ignoreControllerApplet, | ||
int SpetialExitEmulator) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
casing + misspelling
bool ignoreControllerApplet) | ||
: base(inputManager, glLogLevel, aspectRatio, enableMouse, hideCursorMode, ignoreControllerApplet) | ||
bool ignoreControllerApplet, | ||
int SpetialExitEmulator) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
casing + misspelling again
src/Ryujinx/Headless/Options.cs
Outdated
@@ -274,6 +277,9 @@ private static string OptionName(string propertyName) => | |||
[Option("enable-mouse", Required = false, Default = false, HelpText = "Enable or disable mouse support.")] | |||
public bool EnableMouse { get; set; } | |||
|
|||
[Option("enable-press-hotkeys-to-exit", Required = false, Default = 0, HelpText = "press the minus and plus buttons to: 0 -disable, 1 - exit app, 2 - exit game.")] | |||
public int spetialExit { get; set; } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Property name casing + misspelling
bool ignoreControllerApplet) | ||
: base(inputManager, glLogLevel, aspectRatio, enableMouse, hideCursorMode, ignoreControllerApplet) | ||
bool ignoreControllerApplet, | ||
int SpetialExitEmulator) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
casing + misspelling again
src/Ryujinx/Headless/WindowBase.cs
Outdated
@@ -88,6 +88,7 @@ public static void QueueMainThreadAction(Action action) | |||
|
|||
private readonly AspectRatio _aspectRatio; | |||
private readonly bool _enableMouse; | |||
private readonly int _SpetialExitEmulator; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
casing + misspelling
}), | ||
(60, static cff => | ||
{ | ||
cff.SpetialExitEmulator = 1; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
New features should generally be disabled by default; the user may not want the functionality
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I fixed everything
Download the artifacts for this pull request: |
…xed initialization of the new function, defaults to 0
…essing a hotkey (unnecessary check removed)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
viewed
/// <summary> | ||
/// Allows you to choose from three options: do nothing, exit the application, exit the emulator | ||
/// </summary> | ||
public int specialExitEmulator { get; set; } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please, when adding new properties, follow the style of the items you are adding.
SpecialExitEmulator
Adds gamepad exit hotkeys (plus and minus) to the input section. Pressing them simultaneously will trigger one of two events: exit the application or exit the game. This can be disabled. Only works for gamepads