xbmc/xbmc — pull request #3231 by herrnst (2013-09-10 19:33:29+00:00)
Title: screensaver: make musicviz triggered by screensaver-logic behave like a screensaver

This on one side will change the behaviour of the screensaver.usemusicvisinstead - System/Appearance/Screensaver/Use vis if playing audio - setting, but on the other side fix an inconsistency regarding application announcements:

The patch makes musicvisualisations activated via the screensaver logic behave like a "real" screensaver, in that any keyboard input or mouse movement will cancel it and return to the previous window. Manually triggered music vis isn't affected and will (still) prevent the screensaver and dpms stuff from kicking in.

Regarding the mentioned fix: I stumbled upon this while playing around with the python xbmc.Monitor.onScreensaver*() callbacks. All worked as expected, but as soon as a screensaver was triggered as music vis, I received the onScreensaverActivated() callback, but wouldn't ever receive an onScreensaverDeactivated() call when I stopped the screensaving/vis. The System.ScreenSaverActive bool however always returned the correct state.

The patch/PR should be taken as proposal/RFC and should receive some testing. Builds and seems to work good so far on linux.