Skip to content

Control remote device volume by volume keys when MPRIS session is active

Summary

Allows to control the volume of the default sink of the remote device by pressing phone volume keys on API21+ (Lollipop and onwards) when MPRIS session is active (i.e. MPRIS media control notification is present). Remote device should support System Volume Plugin and report its default sink. Volume controlling works both when the phone screen is off and on. When the screen is on, you'll see a new slider in the volume panel (screenshots below).

The code is working, though I'd like to receive feedback on the points below before the request is merged

BUG: 398848

Points to think of

  • Whether this should be always enabled? I have no problems if it's on, but someone may not want to use this feature at all, so adding a switch to plugin settings will solve the problem
  • Currently volume step is hardcoded as 5%. This can be extracted to plugin settings too

Screenshots

Samsung, Android 8 Samsung_Android8

Asus, Android 9 Screenshot_20210326-114140465

Merge request reports

Loading