From eb567c39b1d869ca33a8483695e8c81a274f05a2 Mon Sep 17 00:00:00 2001 From: Papoteur Date: Sat, 20 Jun 2020 15:12:21 +0200 Subject: Distinct Live and classical modes --- qml/mw-ui.qml | 25 ++++++++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) (limited to 'qml/mw-ui.qml') diff --git a/qml/mw-ui.qml b/qml/mw-ui.qml index 169cf1c..000e1e0 100644 --- a/qml/mw-ui.qml +++ b/qml/mw-ui.qml @@ -353,6 +353,25 @@ Rectangle { Links {} } + + ObjectModel { + id: itemModelLive + + // Welcome page + Welcome {} + + // Live mode + Live {} + + // MCC Page + Mcc {} + + // Install software page + Install {} + + // Documentation links + Links {} + } ListView { id: view z: 1 @@ -360,7 +379,7 @@ Rectangle { anchors.leftMargin: 0 anchors.topMargin: 0 anchors { fill: parent; bottomMargin: startCB.implicitHeight +10 } - model: itemModel + model: itemModelLive preferredHighlightBegin: 0; preferredHighlightEnd: 0 highlightRangeMode: ListView.StrictlyEnforceRange orientation: ListView.Horizontal @@ -385,7 +404,7 @@ Rectangle { } Repeater { - model: itemModel.count + model: (user == 'live' ? itemModelLive.count : itemModel.count) Button { Layout.fillHeight: true @@ -399,7 +418,7 @@ Rectangle { color: view.currentIndex == index ? "#2397D4" : "white" } label: Label{ - text: itemModel.get(index).title + text: (user == 'live' ? itemModelLive.get(index).title : itemModel.get(index).title) font.pointSize: 9 color: view.currentIndex == index ? "white" : "#262F45" horizontalAlignment: Text.AlignHCenter -- cgit v1.2.1