<div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div>hi,</div><div>I'm trying to make my app Muuzik - an audio player from the store - recognize bluetooth headset media button without luck.<br></div><div><br></div><div>The headset is paired and works with the default / jolla media app as expected (prev, next, play/pause)<br></div><div><br></div><div>My app provide an mpris2 interface, registered on dbus, it work perfectly from the phone panel (previous, play/stop, next, track info...), I also added a listener on<span style="color:rgb(170,0,0)"> org.mpris.MediaPlayer2</span> and I'm getting callback from other app but nothing when pressing the headset button. Guessing this is not a mpris2 issue.<br></div><div></div><div></div><div><br></div><div>So I tried to work from qml with Permissions / Resource / MediaKey.</div><div>I can "hijack" the volumes buttons with Resource.ScaleButtons - Qt.Key_VolumeUp/Down but nothing working with Resource.HeadsetButtons / Qt.Key_Media*</div><div></div><div></div><div><br></div><div>Here some code : Don't work (but does with Resource.ScaleButtons - Qt.Key_VolumeUp/Down):</div><div><br></div><div>MediaKey {<br>        id: mediaNext<br>        enabled: true<br>        key: Qt.Key_MediaNext<br>        onPressed : {<br>            console.log("expect Key_MediaNext") <br>        }<br>    }<br>Permissions {<br>        enabled: app.applicationActive<br>        autoRelease: true<br>        applicationClass: "player"<br><br>        Resource {<br>            id: headsetAccessResource<br>            type: Resource.HeadsetButtons<br>            optional: false<br>        }</div><div>}<br></div><div><br></div><div>What next solution would you recommend ?</div><div><br></div><div>Thank,</div><div>Jerome.<br></div><div><br></div></div></div></div></div></div></div></div></div>