added previous, next and stop button to ui. Not connected yet

This commit is contained in:
Anika Raemer 2018-12-04 12:17:16 +01:00
parent e610774e49
commit d6c806d41d
6 changed files with 57 additions and 10 deletions

View file

@ -47,18 +47,62 @@ Item{
color: "#99ffffff"
height: 120
RoundButton{
id: startPause
// @todo: use rowLayout instead?
Row{
spacing: 20
anchors.centerIn: parent
width: 80
imageSource: "qrc:/icon_play"
onClicked:{
musicModel.playPause();
if(imageSource == "qrc:/icon_play")
imageSource = "qrc:/icon_pause"
else
imageSource = "qrc:/icon_play"
RoundButton{
id: previous
anchors.verticalCenter: parent.verticalCenter
width: 60
imageSource: "qrc:/icon_previous"
// visible: model.pHasPrevious
onClicked:{
//musicModel.playPrevious();
}
}
RoundButton{
id: playPause
anchors.verticalCenter: parent.verticalCenter
width: 80
imageSource: "qrc:/icon_play"
onClicked:{
musicModel.playPause();
if(imageSource == "qrc:/icon_play")
imageSource = "qrc:/icon_pause"
else
imageSource = "qrc:/icon_play"
}
}
RoundButton{
id: stop
anchors.verticalCenter: parent.verticalCenter
width: 60
imageSource: "qrc:/icon_stop"
onClicked:{
//musicModel.stop();
//playPause.imageSource = "qrc:/icon_play"
}
}
RoundButton{
id: next
anchors.verticalCenter: parent.verticalCenter
width: 60
imageSource: "qrc:/icon_next"
// visible: model.pHasNext
onClicked:{
//musicModel.playNext();
}
}
}
}

View file

@ -5,5 +5,8 @@
<file alias="background">resources/sky.jpg</file>
<file alias="icon_pause">resources/pause.jpg</file>
<file alias="icon_play">resources/play.jpg</file>
<file alias="icon_next">resources/next.jpg</file>
<file alias="icon_previous">resources/previous.jpg</file>
<file alias="icon_stop">resources/stop.jpg</file>
</qresource>
</RCC>

BIN
LenaPi/resources/next.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.3 KiB

BIN
LenaPi/resources/stop.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB