From 6feab72c895fddbfb4add82fda3cb5aa081b63ad Mon Sep 17 00:00:00 2001 From: Michael Zanetti Date: Fri, 11 Jun 2021 15:04:22 +0200 Subject: [PATCH] Allow overriding the connect wizard by the overlay --- nymea-app/ui/ConfigurationBase.qml | 2 ++ nymea-app/ui/RootItem.qml | 4 ++-- nymea-app/ui/components/WizardPageBase.qml | 1 - 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/nymea-app/ui/ConfigurationBase.qml b/nymea-app/ui/ConfigurationBase.qml index 13efed6e..f32cfd6a 100644 --- a/nymea-app/ui/ConfigurationBase.qml +++ b/nymea-app/ui/ConfigurationBase.qml @@ -3,4 +3,6 @@ import QtQuick 2.0 Item { property string systemName: "nymea" property string appName: "nymea:app" + + property string connectionWizard: "/ui/connection/NewConnectionWizard.qml" } diff --git a/nymea-app/ui/RootItem.qml b/nymea-app/ui/RootItem.qml index 819d9201..15e797fe 100644 --- a/nymea-app/ui/RootItem.qml +++ b/nymea-app/ui/RootItem.qml @@ -191,7 +191,7 @@ Item { PlatformHelper.hideSplashScreen(); } - pageStack.push(Qt.resolvedUrl("connection/NewConnectionWizard.qml"), StackView.Immediate) + pageStack.push(Configuration.connectionWizard, StackView.Immediate) } Timer { running: true; repeat: false; interval: 3000; onTriggered: PlatformHelper.hideSplashScreen(); } @@ -202,7 +202,7 @@ Item { if (!engine.jsonRpcClient.currentHost) { print("pushing ConnectPage") tabSettings.lastConnectedHost = "" - pageStack.push(Qt.resolvedUrl("connection/NewConnectionWizard.qml")) + pageStack.push(Configuration.connectionWizard) PlatformHelper.hideSplashScreen(); return; } diff --git a/nymea-app/ui/components/WizardPageBase.qml b/nymea-app/ui/components/WizardPageBase.qml index 496443ca..1634a9a1 100644 --- a/nymea-app/ui/components/WizardPageBase.qml +++ b/nymea-app/ui/components/WizardPageBase.qml @@ -39,7 +39,6 @@ Page { Layout.fillWidth: true Layout.margins: Style.margins wrapMode: Text.WordWrap - text: qsTr("This wizard will guide you through the process of setting up a new nymea system.") horizontalAlignment: Text.AlignHCenter }