Skip to content
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

Inconsistent sound effects when clicking mod icons #5916

Closed
luaneko opened this issue Aug 31, 2019 · 7 comments · Fixed by #5928
Closed

Inconsistent sound effects when clicking mod icons #5916

luaneko opened this issue Aug 31, 2019 · 7 comments · Fixed by #5928

Comments

@luaneko
Copy link
Contributor

luaneko commented Aug 31, 2019

Describe the bug:

When left-clicking on a mod icon, you can hear both checkbox and button sounds.
When right-clicking, you can only hear the checkbox sound.

Screenshots or videos showing encountered issue:
https://streamable.com/n66rj

osu!lazer version: 2019.830.0

Logs: irrelevant

@bdach
Copy link
Collaborator

bdach commented Aug 31, 2019

@phosphene47 Are you sure you haven't mixed up right and left clicks? I hear an extra squeaky sound effect on the left click (sounds like two, and one on right click).

It seems HoverClickSounds.OnClick() does not fire when right-clicking, hence the extra sound effect on left-clicks. Changing HoverClickSounds to just HoverSounds on ModButton would ensure consistency but remove the extra effect. I haven't looked too deeply yet into going the other way (adding the missing effect to the right click), the event would have to be routed to HoverClickSounds.

But then again, I'm not sure that second option would be OK UX-wise, since HoverClickSounds are reused all over the place, even in controls that don't really do anything when right-clicked and therefore probably shouldn't emit a sound effect. Possibly maybe some additional subclassing could be done? (HoverClickSounds -> HoverLeftClickSounds and then a HoverClickSounds that fires the effect on both?)

@luaneko
Copy link
Contributor Author

luaneko commented Aug 31, 2019

That's right, my bad. Left-clicking produces an extra sound.

@bdach
Copy link
Collaborator

bdach commented Sep 4, 2019

Probably worth reopening this after the revert in #5983.

@peppy peppy reopened this Sep 4, 2019
@bdach
Copy link
Collaborator

bdach commented Sep 4, 2019

I'll give this a second go - as discussed, I will be:

  • guarding existing OnClick() handlers with left click checks where relevant,
  • guarding existing ClickEvent cases in Handle() with left click checks where relevant,
  • reviewing existing OnMouseUp() implementations for potential workarounds for the lack of right clicks on OnClick(),
  • finally concluding with changing EnableClick to true in OsuUserInputManager.RightMouseManager

I very much doubt all of this is going to fit in a reviewable PR size-wise, so I'll probably be splitting those changes into three or four. Before I even start working on the code however I'll enumerate all usages I can find and determine whether they need changing or not. I'll attach the reports I generate to the PRs.

I'll also be considering attaching at least some regression tests with the changes, but that might also inflate the volume a lot.

@bdach
Copy link
Collaborator

bdach commented Sep 5, 2019

Here's the preliminary report. Honestly this is a lot and I'm a bit daunted by the amount of changes/PRs/regressions this could generate.

Posting for potential "is it worth it"/UX feedback. By the way, I looked at how right clicks are handled in stable, and it doesn't seem to differentiate between right clicks on buttons and similar UI items (ie. buttons can be clicked with both mouse buttons) - is lazer not handling it the same way intended? I guessed it was, but if it wasn't then a whole lot of those guards won't be necessary.

@peppy
Copy link
Sponsor Member

peppy commented Sep 9, 2019

It's an interesting one. For lazer (and osu-framework) we've been trying to draw from user expectations, checking common UX patterns in all target operating systems (windows / macOS / mobile).

In all of these cases, right click can generally not be used in most places a left click would actuate a control, so I think that is the correct direction (unlike stable).

@peppy peppy removed the bug label Dec 20, 2019
@peppy peppy removed the audio label Feb 12, 2020
@peppy peppy removed this from the Candidate Issues milestone Feb 17, 2020
@Joehuu
Copy link
Member

Joehuu commented May 8, 2022

No longer a problem in the new design (i.e. no more right click).

@Joehuu Joehuu closed this as completed May 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants