2018-11-28 18:41:54 +00:00
|
|
|
import QtQuick 2.11
|
|
|
|
import QtQuick.Controls 2.4
|
|
|
|
import QtQuick.Dialogs 1.3
|
|
|
|
import QtQuick.Layouts 1.11
|
|
|
|
import QtQuick.Window 2.11
|
|
|
|
import Qt.labs.settings 1.0
|
|
|
|
import Qt.labs.platform 1.0 as LabsPlatform
|
|
|
|
import player 1.0
|
|
|
|
|
|
|
|
Item {
|
|
|
|
objectName: "buttonLayout"
|
|
|
|
id: layout
|
2018-11-29 08:25:54 +00:00
|
|
|
anchors.fill: controlsBar
|
2018-11-30 16:42:19 +00:00
|
|
|
height: parent.height
|
2018-11-28 18:41:54 +00:00
|
|
|
|
|
|
|
PlaylistPrevButton {
|
|
|
|
id: playlistPrevButton
|
|
|
|
anchors.left: parent.left
|
|
|
|
anchors.top: parent.top
|
|
|
|
anchors.bottom: parent.bottom
|
|
|
|
width: visible ? playlistNextButton.width : 0
|
2018-11-30 16:42:19 +00:00
|
|
|
icon.height: parent.height / 2
|
|
|
|
icon.width: parent.height / 2
|
2018-11-28 18:41:54 +00:00
|
|
|
}
|
|
|
|
PlayPauseButton {
|
|
|
|
id: playPauseButton
|
|
|
|
anchors.left: playlistPrevButton.right
|
|
|
|
anchors.top: parent.top
|
|
|
|
anchors.bottom: parent.bottom
|
2018-11-30 16:42:19 +00:00
|
|
|
icon.height: parent.height / 2
|
|
|
|
icon.width: parent.height / 2
|
2018-11-28 18:41:54 +00:00
|
|
|
}
|
|
|
|
PlaylistNextButton {
|
|
|
|
id: playlistNextButton
|
|
|
|
anchors.left: playPauseButton.right
|
|
|
|
anchors.top: parent.top
|
|
|
|
anchors.bottom: parent.bottom
|
2018-11-30 16:42:19 +00:00
|
|
|
icon.height: parent.height / 2
|
|
|
|
icon.width: parent.height / 2
|
2018-11-28 18:41:54 +00:00
|
|
|
}
|
|
|
|
|
2018-12-05 12:13:28 +00:00
|
|
|
MouseArea {
|
|
|
|
id: mouseAreaVolumeArea
|
|
|
|
anchors.bottom: parent.bottom
|
|
|
|
anchors.left: volumeButton.left
|
|
|
|
anchors.right: volumeSlider.right
|
|
|
|
anchors.top: parent.top
|
|
|
|
width: volumeButton.width
|
|
|
|
+ (volumeSlider.visible ? volumeSlider.width : 0)
|
|
|
|
hoverEnabled: true
|
|
|
|
propagateComposedEvents: true
|
|
|
|
acceptedButtons: Qt.NoButton
|
|
|
|
}
|
|
|
|
|
2018-11-28 18:41:54 +00:00
|
|
|
VolumeButton {
|
|
|
|
id: volumeButton
|
|
|
|
anchors.left: playlistNextButton.right
|
|
|
|
anchors.top: parent.top
|
|
|
|
anchors.bottom: parent.bottom
|
2018-11-30 16:42:19 +00:00
|
|
|
icon.height: parent.height / 2
|
|
|
|
icon.width: parent.height / 2
|
2018-11-28 18:41:54 +00:00
|
|
|
}
|
|
|
|
VolumeSlider {
|
|
|
|
id: volumeSlider
|
|
|
|
anchors.left: volumeButton.right
|
|
|
|
anchors.top: parent.top
|
|
|
|
anchors.bottom: parent.bottom
|
2018-11-30 16:42:19 +00:00
|
|
|
height: parent.height
|
2018-12-05 12:13:28 +00:00
|
|
|
visible: mouseAreaVolumeArea.containsMouse || volumeButton.hovered
|
|
|
|
width: visible ? implicitWidth : 0
|
2018-11-28 18:41:54 +00:00
|
|
|
}
|
|
|
|
TimeLabel {
|
|
|
|
anchors.left: volumeSlider.right
|
|
|
|
anchors.top: parent.top
|
|
|
|
anchors.bottom: parent.bottom
|
|
|
|
}
|
|
|
|
|
|
|
|
SettingsButton {
|
|
|
|
id: settingsButton
|
|
|
|
anchors.right: fullscreenButton.left
|
|
|
|
anchors.top: parent.top
|
|
|
|
anchors.bottom: parent.bottom
|
2018-11-30 16:42:19 +00:00
|
|
|
icon.height: parent.height / 2
|
|
|
|
icon.width: parent.height / 2
|
2018-11-28 18:41:54 +00:00
|
|
|
}
|
|
|
|
FullscreenButton {
|
|
|
|
id: fullscreenButton
|
|
|
|
anchors.right: parent.right
|
|
|
|
anchors.top: parent.top
|
|
|
|
anchors.bottom: parent.bottom
|
2018-11-30 16:42:19 +00:00
|
|
|
icon.height: parent.height / 2
|
|
|
|
icon.width: parent.height / 2
|
2018-11-28 18:41:54 +00:00
|
|
|
}
|
|
|
|
}
|