-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refs #2, Dashboards now have their own StackView.
- Loading branch information
Showing
9 changed files
with
104 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import QtQuick 2.15 | ||
|
||
Item { | ||
id: baseDelegate | ||
property Item stackView: dashboardStackView ? dashboardStackView : null | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
72 changes: 72 additions & 0 deletions
72
Frontend/DashboardsViewer/content/widgets/SessionViewerWidget.qml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
import QtQuick 2.15 | ||
import QtQuick.Controls 2.15 | ||
import QtQuick.Layouts 2.15 | ||
import DashboardsViewer 1.0 | ||
|
||
BaseWidget { | ||
id:mySessionViewerWidget | ||
property var session: null | ||
|
||
Rectangle { | ||
id: background | ||
anchors.fill: parent | ||
color: Constants.backgroundColor | ||
|
||
ColumnLayout { | ||
id: sessionLayout | ||
spacing: 10 | ||
anchors.fill: parent | ||
anchors.margins: 10 | ||
Button { | ||
id: button | ||
Layout.fillWidth: false | ||
Layout.fillHeight: false | ||
Layout.alignment: Qt.AlignRight | ||
implicitWidth: 200 | ||
implicitHeight: 50 | ||
text: "Click me to close." | ||
onClicked: { | ||
console.log("Button clicked") | ||
if (stackView.currentItem === mySessionViewerWidget) { | ||
stackView.pop(); | ||
} | ||
} | ||
} | ||
|
||
Rectangle { | ||
id: sessionName | ||
Layout.fillWidth: true | ||
Layout.fillHeight: false | ||
implicitHeight: 30 | ||
color: "lightblue" | ||
Text { | ||
id: sessionNameText | ||
text: session.session_name | ||
font.bold: true | ||
font.pointSize: 20 | ||
anchors.centerIn: parent | ||
} | ||
} | ||
Rectangle { | ||
id: sessionComments | ||
Layout.fillWidth: true | ||
Layout.fillHeight: false | ||
implicitHeight: 30 | ||
color: "lightyellow" | ||
Text { | ||
id: sessionCommentsText | ||
text: session.session_comments | ||
font.pointSize: 16 | ||
anchors.fill: parent | ||
wrapMode: Text.Wrap | ||
} | ||
} | ||
} | ||
|
||
} | ||
|
||
|
||
Component.onCompleted: { | ||
console.log("Item completed") | ||
} | ||
} |