Having the mediaplayer application pause the radio was requested as
a demo behavior improvement. Use the new radio binding support in
libqtappfw to do so.
Change-Id: I6b2aa6c2c03a2485dfb05406ec450c126995440c
Signed-off-by: Scott Murray <scott.murray@konsulko.com>
id: previous
offImage: './images/AGL_MediaPlayer_BackArrow.svg'
onClicked: {
+ radio.stop()
mediaplayer.previous()
}
}
PropertyChanges {
target: play
offImage: './images/AGL_MediaPlayer_Player_Play.svg'
- onClicked: mediaplayer.play()
+ onClicked: {
+ radio.stop()
+ mediaplayer.play()
+ }
}
}
]
id: forward
offImage: './images/AGL_MediaPlayer_ForwardArrow.svg'
onClicked: {
+ radio.stop()
mediaplayer.next()
}
}
//}
}
onClicked: {
+ radio.stop()
mediaplayer.picktrack(playlistview.model[index].index)
}
}
#include <libhomescreen.hpp>
#include <qlibwindowmanager.h>
#include <mediaplayer.h>
+#include <radio.h>
#include <unistd.h>
});
context->setContextProperty("mediaplayer", new Mediaplayer(bindingAddress, context));
+ context->setContextProperty("radio", new Radio(bindingAddress, context));
context->setContextProperty(QStringLiteral("screenInfo"), &screenInfo);
engine.load(QUrl(QStringLiteral("qrc:/MediaPlayer.qml")));
<param name="windowmanager" value="ws" />
<param name="homescreen" value="ws" />
<param name="mediaplayer" value="ws" />
+ <param name="radio" value="ws" />
</feature>
<feature name="urn:AGL:widget:required-permission">
<param name="urn:AGL:permission::public:no-htdocs" value="required" />