swift
setuploadingdialog.cpp
1 // SPDX-FileCopyrightText: Copyright (C) 2017 swift Project Community / Contributors
2 // SPDX-License-Identifier: GPL-3.0-or-later OR LicenseRef-swift-pilot-client-1
3 
4 #include "setuploadingdialog.h"
5 
6 #include <QDesktopServices>
7 #include <QPushButton>
8 
9 #include "ui_setuploadingdialog.h"
10 
11 #include "core/setupreader.h"
13 #include "gui/guiapplication.h"
14 #include "misc/swiftdirectories.h"
15 
16 using namespace swift::misc;
17 using namespace swift::misc::network;
18 using namespace swift::core;
19 using namespace swift::core::data;
20 
21 namespace swift::gui::components
22 {
23  CSetupLoadingDialog::CSetupLoadingDialog(QWidget *parent) : QDialog(parent), ui(new Ui::CSetupLoadingDialog)
24  {
25  Q_ASSERT_X(sApp, Q_FUNC_INFO, "Need sApp");
26 
27  ui->setupUi(this);
28 
29  const QString bootstrapPath = CSwiftDirectories::bootstrapResourceFilePath();
30  ui->lbl_ownBootstrap->setText("Your boostrap.json file is available at <a href=" + bootstrapPath + ">" +
31  bootstrapPath + "</>");
32 
33  // hide unnecessary details
34  ui->comp_Messages->hideFilterBar();
35  ui->comp_Messages->showDetails(false);
36  }
37  CSetupLoadingDialog::CSetupLoadingDialog(const CStatusMessageList &msgs, QWidget *parent)
38  : CSetupLoadingDialog(parent)
39  {
40  ui->comp_Messages->appendStatusMessagesToList(msgs);
41  }
42 
44 } // namespace swift::gui::components
SWIFT_CORE_EXPORT swift::core::CApplication * sApp
Single instance of application object.
Definition: application.cpp:71
Setup dialog, if loading the boostrap file fails.
Status messages, e.g. from Core -> GUI.
Core data traits (aka cached values) and classes.
Backend services of the swift project, like dealing with the network or the simulators.
Definition: actionbind.cpp:7
High level reusable GUI components.
Definition: aboutdialog.cpp:13
Free functions in swift::misc.