Bug 346323 - configure programs for prevent autosuspend
Summary: configure programs for prevent autosuspend
Status: RESOLVED NOT A BUG
Alias: None
Product: Powerdevil
Classification: Plasma
Component: general (show other bugs)
Version: 5.2.2
Platform: Arch Linux Linux
: NOR wishlist
Target Milestone: ---
Assignee: Plasma Development Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-04-17 21:36 UTC by miku84
Modified: 2015-04-18 16:22 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description miku84 2015-04-17 21:36:14 UTC
I have autosuspend configured after 10minutes in Plasma5 and it goes suspended when nothing happens, only song playing. I think it should not go to suspend as VLC and qbittorrent does not go to suspend when active. 

Monitor could be off after 5 minutes but not the PC.


Reproducible: Always

Steps to Reproduce:
1.configure autosuspend : 5minutes
2.listen some music
3.PC goes to suspend

Actual Results:  
3.PC goes to suspend

Expected Results:  
Not to suspend when media is played:
- fullscreen apps: browsers
- music
- movie

Each program should be configurable:
- allow prevent monitor off 
- allow prevent sleep
Comment 1 Kai Uwe Broulik 2015-04-17 21:41:56 UTC
Thanks for your bug report! However it is job of the application to block automatic suspending, and applications like vlc, Amarok and others actually do. If not, that's a bug in the application, especially since there is a standardized interface that any application can use to prevent suspending.
Comment 2 Kai Uwe Broulik 2015-04-17 21:44:48 UTC
In addition KDE application can decide whether to turn off the screen or suspend, whereas the standardized cross platform interface unfortunately only allows all or nothing. There's not much we can do.
Comment 3 miku84 2015-04-18 14:43:11 UTC
Kmediaplayer detects if some application plays mucis or movie.
If Kmediaplayer is running, it should prevent sleep.
Are you saying that this can be done?  How?

Thanks.
Comment 4 Kai Uwe Broulik 2015-04-18 14:48:43 UTC
The application needs to call Inhibit on the org.freedesktop.PowerManagement.Inhibit DBus interface.
Comment 5 miku84 2015-04-18 14:59:43 UTC
I see that the application can do this but if KDE apps can decide whether or not go to suspend as you say, then I think Kmediaplayer could control it.
As this Kmediaplayer program already know when music or movie is played then this configuration could be very useful, it could also call  Inhibit on the org.freedesktop.PowerManagement.Inhibit DBus interface.
Comment 6 Martin Flöser 2015-04-18 16:22:42 UTC
First of all: what's kmediaplayer?

Let's assume this "kmediaplayer" does it. It has no idea whether the application already inhibited it. Even more if it unconditionally inhibits it would also inhibit even if you as a user disabled in your media player (e.g. VLC) that it inhibits. So it would do the opposite from what the user expects.

It's just something the application has to do, we cannot apply "magic" here.