1
0
Fork 0
VideoPlayer/src/qml/YouTubeButtonLayout.qml

93 lines
1.7 KiB
QML
Raw Normal View History

import QtQuick 2.0
import player 1.0
Item {
2020-05-06 12:43:01 +01:00
objectName: "buttonLayout"
id: layout
anchors.fill: controlsBar
height: parent.height
2020-05-06 12:43:01 +01:00
PlaylistPrevButton {
id: playlistPrevButton
anchors {
left: parent.left
top: parent.top
bottom: parent.bottom
}
2020-05-06 12:43:01 +01:00
width: visible ? playlistNextButton.width : 0
}
PlayPauseButton {
id: playPauseButton
anchors {
left: playlistPrevButton.right
top: parent.top
bottom: parent.bottom
}
2020-05-06 12:43:01 +01:00
leftPadding: 14
}
PlaylistNextButton {
id: playlistNextButton
anchors {
left: playPauseButton.right
top: parent.top
bottom: parent.bottom
}
2020-05-06 12:43:01 +01:00
}
2020-05-06 12:43:01 +01:00
MouseArea {
id: mouseAreaVolumeArea
anchors.fill: volumeSlider
width: volumeSlider.width
hoverEnabled: true
propagateComposedEvents: true
acceptedButtons: Qt.NoButton
z: 100
}
2020-05-06 12:43:01 +01:00
VolumeButton {
id: volumeButton
anchors {
left: playlistNextButton.right
top: parent.top
bottom: parent.bottom
}
2020-05-06 12:43:01 +01:00
z: 50
}
VolumeSlider {
id: volumeSlider
anchors {
left: volumeButton.right
top: parent.top
bottom: parent.bottom
}
2020-05-06 12:43:01 +01:00
height: parent.height
visible: mouseAreaVolumeArea.containsMouse || volumeButton.hovered
width: visible ? implicitWidth : 0
}
TimeLabel {
anchors {
left: volumeSlider.right
top: parent.top
bottom: parent.bottom
leftMargin: parent.width / 128
}
2020-05-06 12:43:01 +01:00
}
2020-05-06 12:43:01 +01:00
SettingsButton {
id: settingsButton
anchors {
right: fullscreenButton.left
top: parent.top
bottom: parent.bottom
}
2020-05-06 12:43:01 +01:00
}
FullscreenButton {
id: fullscreenButton
anchors {
right: parent.right
top: parent.top
bottom: parent.bottom
}
2020-05-06 12:43:01 +01:00
}
}