Comment 17 for bug 1426115

Revision history for this message
Michael Terry (mterry) wrote :

Looking into the ubuntu-push issue... I feel like it's weird that the turn-on-screen code is spread around the place. It seems like logically, the component that is showing the notification on the screen should be turning the screen on. It doesn't feel like a telephony-service decision, for example.

It would also mean that we wouldn't miss cases like ubuntu-push or even direct dbus notifications:

import dbus
bus = dbus.SessionBus()
proxy = bus.get_object('org.freedesktop.Notifications', '/org/freedesktop/Notifications')
interface = dbus.Interface(proxy,dbus_interface='org.freedesktop.Notifications')
interface.Notify('Notification', 0, '', 'Testing 123', 'Hello World', [], {}, 0)

I guess that would mean either turning on the screen in unity-notifications or unity8. And it feels like a different bug should be opened for unifying calls to setScreenPowerMode in one place. For this bug, I've filed MPs for all the existing calls to setScreenPowerMode I could find, to update their 'reason' parameter to use the new NOTIFICATION reason.