From 5083865626cfd50e66d570308e88b1e3d2354152 Mon Sep 17 00:00:00 2001 From: Chris Cochrun Date: Fri, 21 Oct 2022 10:38:50 -0500 Subject: [PATCH] adjusting small ui changes --- src/qml/main.qml | 9 ++++++--- src/qml/presenter/MainWindow.qml | 1 + src/qml/presenter/Presentation.qml | 7 +++---- 3 files changed, 10 insertions(+), 7 deletions(-) diff --git a/src/qml/main.qml b/src/qml/main.qml index 1c06d4a..7e22ac1 100644 --- a/src/qml/main.qml +++ b/src/qml/main.qml @@ -26,7 +26,7 @@ Kirigami.ApplicationWindow { onActiveFocusItemChanged: print("FOCUS CHANGED TO: " + activeFocusControl) - pageStack.initialPage: mainPage + /* pageStack.initialPage: mainPage */ header: Presenter.Header {} menuBar: Controls.MenuBar { @@ -86,7 +86,10 @@ Kirigami.ApplicationWindow { onTriggered: saveAs() } Labs.MenuSeparator { } - Labs.MenuItem { text: qsTr("Quit") } + Labs.MenuItem { + text: qsTr("Quit") + onTriggered: rootApp.quit() + } } Labs.Menu { title: qsTr("Settings") @@ -108,6 +111,7 @@ Kirigami.ApplicationWindow { Presenter.MainWindow { id: mainPage + anchors.fill: parent } FileDialog { @@ -216,5 +220,4 @@ Kirigami.ApplicationWindow { id: settingsSheet theModel: screenModel } - } diff --git a/src/qml/presenter/MainWindow.qml b/src/qml/presenter/MainWindow.qml index 4c0af6b..736321f 100644 --- a/src/qml/presenter/MainWindow.qml +++ b/src/qml/presenter/MainWindow.qml @@ -80,6 +80,7 @@ Controls.Page { FocusScope { id: mainPageArea Controls.SplitView.fillWidth: true + Controls.SplitView.fillHeight: true Controls.SplitView.minimumWidth: 100 Presenter.Presentation { diff --git a/src/qml/presenter/Presentation.qml b/src/qml/presenter/Presentation.qml index d91341b..b139238 100644 --- a/src/qml/presenter/Presentation.qml +++ b/src/qml/presenter/Presentation.qml @@ -36,6 +36,7 @@ FocusScope { GridLayout { anchors.fill: parent + /* anchors.bottomMargin: 40 */ columns: 3 rowSpacing: 5 columnSpacing: 0 @@ -130,11 +131,11 @@ FocusScope { spacing: 2 Layout.preferredWidth: previewSlide.width - 50 /* Layout.columnSpan: 3 */ + visible: itemType === "video"; Kirigami.Icon { source: previewSlide.mpvIsPlaying ? "media-pause" : "media-play" Layout.preferredWidth: 25 Layout.preferredHeight: 25 - visible: itemType === "video"; MouseArea { anchors.fill: parent onPressed: SlideObject.playPause(); @@ -143,7 +144,6 @@ FocusScope { } Controls.Slider { id: videoSlider - visible: itemType === "video"; Layout.fillWidth: true Layout.preferredHeight: 25 from: 0 @@ -155,7 +155,6 @@ FocusScope { Controls.Switch { text: "Loop" - visible: itemType === "video"; checked: previewSlide.mpvLoop === "inf" ? true : false onToggled: mainPage.loopVideo() Keys.onLeftPressed: previousSlideAction() @@ -249,7 +248,7 @@ FocusScope { } Item { - /* Layout.preferredHeight: 200 */ + /* Layout.preferredHeight: 20 */ Layout.fillHeight: true Layout.fillWidth: true Layout.columnSpan: 3