Bugzilla – Bug 2241
Auto dimming is broken when screensaver is set to none
Last modified: 2009-09-08 09:28:14 UTC
The auto dimming feature remembers the brightness that is last set during an on screensaver mode, and auto-dims to that brightness, regardless of whether the screensaver is enabled. This is fine, the problem comes if you want to change the brightness that is dimmed to. With screensavers enabled, I just press brightness whilst the screensaver is on, and it changes the screensaver brightness. However, with screensaver set to none, there is no way to change the brightness that is dimmed to. If the display auto-dims, any press of brightness changes the non-dimmed level. You can easily get into a situation where the "dimmed" brightness is higher than the normal one, and the only way to stop it is to enable a screensaver, wait for it to dim, change the brightness then disable the screensaver. Steps to reproduce: - Enable the Analog VU screensaver for screensaver whilst playing - Enable the auto-dimming feature - Set display brightness to lowest (but not off!) - Listen to music and wait for screensaver to kick in - Press brightness until display is at maximum brightness - Cancel screensaver and set screensaver for whilst playing to None - Dim display back down to low level - Listen to music again - After a short while, the brightness should jump back up to full - Press brightness to make it dim again and wait - It will soon jump back up to full brightness! As Dean says, "Ick"!
Created attachment 885 [details] insane check for screensaver something like this should help. Really, what I've added would work as a generic test, but the other cases are useful for a quick pass. ($client->brightness() == $client->prefGet('idleBrightness') may not be needed, but I dont have time to test right now.
nix that patch. brightness would update irtime, so its useless. This will require a new fake 'mode' or flag instead.
one solution would be to trap the brightness function earlier on, and not update irtime. however, this is a problem since brightness.single is used for the function. brightness is just a dead function (in fact, not even dead, just blank). This causes an unconditional update of irtime. It could be mapped properly to 'dead', and we could ignore 'dead' for the purposes of lastIRTime.
Created attachment 886 [details] treat 'dead' and 'brightness' functions as non-ir events This bypasses the lastirtime update when the function is mapped to dead or some variant of brightness. Now, we can check against the lastirtime to know that the screensaver timeout has passed. This also avoids waking up the display on 'dead' ir events. May also want to avoid wakeup for null events as well, but that's another issue.
Patch looks reasonable.
committed at change 4543
There are 536 bugs in the database with targets of '---' that were fixed prior to new year 2006. I am setting them to targets of 6.2.1 to keep them from showing up in my queries.