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
DolphinQt: Add option to always show Mouse Cursor #10121
DolphinQt: Add option to always show Mouse Cursor #10121
Conversation
|
Wouldn't it be better if this was a radio button menu? |
This seems like a much cleaner approach and will make end-user experience less confusing. I will apply this change later. Thanks for your suggestion! |
b7c3a49
to
5803e9d
Compare
|
Radio buttons have been added. I don't know if this was the cleanest way to implement the functionality (particularly my use of the enum). |
|
Small nitpick but I think it's important to have "cursor" in the Group Box title, the current "Hide Mouse" title can be a bit ambiguous. I would probably go with "Mouse Cursor Hiding"... |
ff4403d
to
e87c633
Compare
|
I think the header could read "Mouse Cursor Visibility" but the options "Always" and "Never" should be swapped. |
I agree again. I do think Delay was a bit ambiguous and switching the header and the radio button label gives a better explanation. Although, the mouse cursor, when hidden after the timer expires, does NOT reappear on movement. It actually reappears on the next click... That being said, should the behavior instead by changed to make the cursor visible on movement, or keep it on click? EDIT: Turns out that's a bug. Looks like the implementation assumes that the timer resets on mouse movement, but it's written within a case statement checking for MouseButtonPress... Gonna fix that and update the commit |
a079bc6
to
011b1be
Compare
011b1be
to
45848b3
Compare
|
UI looks good to me. However I have a small question - with the On Movement setting, how long after movement is stopped until the mouse cursor disappears? |
It is currently set to disappear after 3 seconds of inactivity which is the default behavior prior to this PR. |
I think one and a half seconds can be the default time. |
|
I think 3 seconds is fine. If we want to change it, let's do it in a separate PR so this one doesn't get bikeshedded to hell. |
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.
Reviewed 9 of 9 files at r1, all commit messages.
Reviewable status: all files reviewed, 3 unresolved discussions (waiting on @Filoppi and @malleoz)
Source/Core/Core/ConfigManager.h, line 150 at r1 (raw file):
bool bConfirmStop = false; enum ShowCursor
enum class
Source/Core/Core/ConfigManager.h, line 154 at r1 (raw file):
Never, Constantly, Movement
"OnMovement" for consistency with the other options? Also please add a trailing comma here.
Previously the unhide of movement mouse_timer reset occurred within case MouseButtonPress. Additionally, there was a redundant expression in the if statement for cursor locking.
Instead of having a single GUI checkbox for "Always Hide Mouse Cursor", I have instead opted to use radio buttons so the user can swap between different states of mouse visibility. "Movement" is the default behavior, "Never" will hide the mouse cursor the entire time the game is running, and "Always" will keep the mouse cursor always visible.
45848b3
to
2aa400e
Compare
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.
Reviewed 4 of 4 files at r2, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @Filoppi)
Adds a toggle in Config->Interface to always keep the mouse cursor visible. It seemed unusual that this wasn't possible before in DolphinQt.
Additionally, a bug meant that the default behavior of the mouse re-appearing on movement did not work... The mouse would only re-appear on clicking. Thus, I've also included a bug fix for this.
Left is current Dolphin dev. Right is the changes made in this pull request.