Fix 8c58fb1efd: Doubled beep sounds when clicking toolbar buttons.

* ShowDropDownList() now issues a beep, so individual toolbar buttons no longer need to do it.
* HandleButtonClick() may be called twice for some buttons, as it is called by automatically for PUSH buttons.

This caused some beeps to sound louder than others.
This commit is contained in:
Peter Nelson
2025-09-21 01:00:20 +01:00
committed by dP
parent 94979e1f08
commit a32547e8fd
2 changed files with 3 additions and 14 deletions
+3
View File
@@ -594,6 +594,9 @@ EventState Window::OnHotkey(int hotkey)
*/
void Window::HandleButtonClick(WidgetID widget)
{
/* Button click for this widget may already have been handled. */
if (this->IsWidgetLowered(widget) && this->timeout_timer == TIMEOUT_DURATION) return;
this->LowerWidget(widget);
this->SetTimeout();
this->SetWidgetDirty(widget);