Prevent display turning off when playing media

It’s possible to inhibit the display turn off in kde using ``kde-inhibit --power --screenSaver ``` However, I want to inhibit the display turning off only when playing media (either by spotify or a browser), and let it sleep as usual when not playing media.

How could I achieve this? Is there a lower level solution that doesn’t envolve the DE’s setting?

JC1,

I use qtile on X11 and hyprland on Wayland. There is an option on hyprland for exactly that (idleinhibit window rule), but didn’t find a good solution on qtile yet. Anyway I have issues with qtile for other things too (because of X11 mainly).

lemmyvore,

Try putting the browser on fullscreen, see if that keeps the screen alive while playing.

rotopenguin,
@rotopenguin@infosec.pub avatar

That thing usually goes by the name “wake lock”. I can’t imagine why it’s not doing the right thing by default.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • linux@lemmy.ml
  • DreamBathrooms
  • mdbf
  • ethstaker
  • magazineikmin
  • GTA5RPClips
  • rosin
  • thenastyranch
  • Youngstown
  • InstantRegret
  • slotface
  • osvaldo12
  • kavyap
  • khanakhh
  • Durango
  • megavids
  • everett
  • cisconetworking
  • normalnudes
  • tester
  • ngwrru68w68
  • cubers
  • modclub
  • tacticalgear
  • provamag3
  • Leos
  • anitta
  • JUstTest
  • lostlight
  • All magazines