As deivce comes back from lock, the back-light level becomes max instead of the last set value
Bug #1287599 reported by
Yuan-Chen Cheng
This bug affects 3 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
indicator-power |
Fix Released
|
High
|
Yuan-Chen Cheng | ||
indicator-power (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned | ||
powerd (Ubuntu) |
Fix Released
|
High
|
Yuan-Chen Cheng |
Bug Description
Currently powerd is control the backlight on/off, and indicator-power is control how bright is should be.
The backlight brightness level should be consistent within those two process. (Currently not)
To reproduce:
On n4 with dev channl rel 194
1. open power indicator (or app "System Settings", choose battery and set the brightness)
2. set the brightness level to certain point (make it lower so that you can see it more clearly)
3. press power button to lock the device
4. press power button to unlock the device
Expected result:
Brightness level is the one we set in the indicator
Current result:
Brightness level is always in a value that's relative high.
Related branches
lp:~ycheng-twn/powerd/powerd_allow-non-root-dbus-cmd
- Ricardo Salveti (community): Approve
-
Diff: 83 lines (+46/-9)2 files modifiedcli/powerd-cli.c (+1/-2)
debian/powerd.conf (+45/-7)
lp:~ycheng-twn/indicator-power/indicator-power_set-brightness-via-powerd
- Ricardo Salveti (community): Approve
- Yuan-Chen Cheng (community): Needs Resubmitting
- Charles Kerr (community): Approve
-
Diff: 353 lines (+269/-4)4 files modifiedsrc/Makefile.am (+2/-0)
src/ib-brightness-powerd-control.c (+181/-0)
src/ib-brightness-powerd-control.h (+42/-0)
src/service.c (+44/-4)
Changed in indicator-power: | |
assignee: | nobody → Yuan-Chen Cheng (ycheng-twn) |
Changed in indicator-power: | |
status: | New → In Progress |
Changed in indicator-power: | |
importance: | Undecided → High |
Changed in powerd (Ubuntu): | |
importance: | Undecided → High |
status: | New → In Progress |
assignee: | nobody → Yuan-Chen Cheng (ycheng-twn) |
Changed in indicator-power: | |
status: | In Progress → Fix Released |
To post a comment you must log in.
Analysis:
- powerd control backlight by using android library through hybris.
- powerd currently have dbus method that can adjust brightness, and it will remember the value of brightness if the value is set via dbus method. currently the dbus method only allow process with root account to use.
- indicator-power control backlight by find the backlight device throught udev matching rule.
Proposed solution:
- modify the powerd to allow method call from non-root process (indicator-power run by account phablet)
- modify indicator-power to check whether the bus name that powerd use is claimed. If yes, it use dbus method to control backlight. Or else it fall back to udev matching rule to find backlight device node.