diff --git a/client/ui/controllers/pageController.cpp b/client/ui/controllers/pageController.cpp index 7b8f74ab4..2a14548c0 100644 --- a/client/ui/controllers/pageController.cpp +++ b/client/ui/controllers/pageController.cpp @@ -37,6 +37,8 @@ PageController::PageController(const QSharedPointer &serversModel, connect(this, &PageController::raiseMainWindow, []() { setDockIconVisible(true); }); connect(this, &PageController::hideMainWindow, []() { setDockIconVisible(false); }); #endif + + m_bConnectTrigger = false; } QString PageController::getInitialPage() @@ -145,3 +147,13 @@ void PageController::drawerClose() m_drawerLayer = 0; } } + +bool PageController::isConnectTrigger() +{ + return m_bConnectTrigger; +} + +void PageController::setConnectTrigger(bool trigger) +{ + m_bConnectTrigger = trigger; +} diff --git a/client/ui/controllers/pageController.h b/client/ui/controllers/pageController.h index a8f883fe1..d16c36a6d 100644 --- a/client/ui/controllers/pageController.h +++ b/client/ui/controllers/pageController.h @@ -84,6 +84,10 @@ public slots: void drawerOpen(); void drawerClose(); + + bool isConnectTrigger(); + void setConnectTrigger(bool trigger); + signals: void goToPage(PageLoader::PageEnum page, bool slide = true); void goToStartPage(); @@ -120,6 +124,8 @@ public slots: PageLoader::PageEnum m_currentRootPage; int m_drawerLayer; + + bool m_bConnectTrigger; }; #endif // PAGECONTROLLER_H diff --git a/client/ui/qml/Components/ConnectButton.qml b/client/ui/qml/Components/ConnectButton.qml index b7484c733..b5c94ea85 100644 --- a/client/ui/qml/Components/ConnectButton.qml +++ b/client/ui/qml/Components/ConnectButton.qml @@ -139,6 +139,8 @@ Button { onClicked: { if (!ContainersModel.isAnyContainerInstalled()) { + PageController.setConnectTrigger(true) + ServersModel.currentlyProcessedIndex = ServersModel.getDefaultServerIndex() PageController.goToPage(PageEnum.PageSetupWizardEasy) diff --git a/client/ui/qml/Pages2/PageSetupWizardEasy.qml b/client/ui/qml/Pages2/PageSetupWizardEasy.qml index 4f94e9851..08542b23b 100644 --- a/client/ui/qml/Pages2/PageSetupWizardEasy.qml +++ b/client/ui/qml/Pages2/PageSetupWizardEasy.qml @@ -183,7 +183,16 @@ PageType { textColor: "#D7D8DB" borderWidth: 1 - visible: ContainersModel.isAnyContainerInstalled() + visible: { + if (PageController.isConnectTrigger()) { + PageController.setConnectTrigger(false) + + return ContainersModel.isAnyContainerInstalled() + } + + + return true + } text: qsTr("Set up later")