[screenlocker] Support global shortcuts in the lock screen
Review Request #122419 - Created Feb. 4, 2015 and submitted
This change implements support for white listed global shortcuts in
the lock screen. It interacts with KGlobalAccel to fetch shortcuts
and checks them when a key is pressed. For more detailed information
on how this functions, please see the documentation added to the new
So far only shortcuts from kmix are white listed. This allows to
mute and change volume while the screen is locked.
So far only with the test application
why bother doing this and the check in init? It's not like kglobal accel is going to reset whilst the locker is active, and even if it does close we don't need to react differently.
It's DBus activated so the right thing to do (TM) is to call ListNames regardless, and to call Invoke regardless. The DBus server will start up kglobalaccel5 if it's not running; and if it can't run you get an error which you handle anyway.
you can just remove m_connected, and the entirity of init().
Also as-is you have a race if lock is called before init's ListName finishes which would make shortcuts not work in that instance
if we're treating this as a bool, why not just make it a bool?
The only person that increments this is this method, and that will only do it when it's m_updatingInformation is 0.
you're not handling emacs style shortcuts here.
Dropped the dbus service watcher. Tested, whether kglobalaccel gets started properly if not running.
Revision 2 (+371 -1)