Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#16354 closed bug (fixed)

Revert button needs to be clicked twice to activate after brightness was changed

Reported by: accessays Owned by: axeld
Priority: low Milestone: R1/beta3
Component: Preferences/Screen Version: R1/Development
Keywords: brightness, screen, revert Cc:
Blocked By: Blocking:
Platform: x86-64

Description

In Screen Preferences, after changing brightness slider the Revert button needs to be clicked twice to disable it. Brightness is restored to its original value after the first click, but the Revert button continues being enabled.

Attachments (1)

revert_button_fix.patch (560 bytes ) - added by accessays 4 years ago.
Proposed fix

Download all attachments as: .zip

Change History (6)

by accessays, 4 years ago

Attachment: revert_button_fix.patch added

Proposed fix

comment:1 by accessays, 4 years ago

Clicking Revert button ends up calling _UpdateActiveMode which calls _UpdateControls which calls _CheckApplyEnabled, which enables or disables the Revert button. In message handler (for BUTTON_REVERT_MSG) _UpdateActiveMode is called before brightness is reset, so Revert button stays enabled.

Attached patch is one way to fix that, by simply calling _UpdateActiveMode after brightness has been reset.

comment:2 by diver, 4 years ago

Please push it to http://review.haiku-os.org.

comment:3 by accessays, 4 years ago

https://review.haiku-os.org/c/haiku/+/2989

Took a while to set up Gerrit, hopefully correctly.

comment:4 by waddlesplash, 4 years ago

Resolution: fixed
Status: newclosed

Merged in hrev54393. Thanks!

comment:5 by pulkomandy, 4 years ago

Milestone: UnscheduledR1/beta3
Note: See TracTickets for help on using tickets.