PIVX Core  5.6.99
P2P Digital Currency
masternodewizarddialog.h
Go to the documentation of this file.
1 // Copyright (c) 2019-2022 The PIVX Core developers
2 // Distributed under the MIT software license, see the accompanying
3 // file COPYING or http://www.opensource.org/licenses/mit-license.php.
4 
5 #ifndef PIVX_QT_MASTERNODEWIZARDDIALOG_H
6 #define PIVX_QT_MASTERNODEWIZARDDIALOG_H
7 
8 #include "focuseddialog.h"
9 #include "masternodeconfig.h"
10 #include "pwidget.h"
11 #include "snackbar.h"
12 
13 class MNModel;
14 class WalletModel;
15 
16 namespace Ui {
18 class QPushButton;
19 }
20 
21 class MasterNodeWizardDialog : public FocusedDialog, public PWidget::Translator
22 {
23  Q_OBJECT
24 
25 public:
26  explicit MasterNodeWizardDialog(WalletModel* walletMode,
28  QWidget *parent = nullptr);
29  ~MasterNodeWizardDialog() override;
30  void showEvent(QShowEvent *event) override;
31  QString translate(const char *msg) override { return tr(msg); }
32 
33  QString returnStr = "";
34  bool isOk = false;
36 
37 private Q_SLOTS:
38  void accept() override;
39  void onBackClicked();
40 private:
41  Ui::MasterNodeWizardDialog *ui;
42  QPushButton* icConfirm1;
43  QPushButton* icConfirm3;
44  QPushButton* icConfirm4;
45  SnackBar *snackBar = nullptr;
46  int pos = 0;
47 
49  MNModel* mnModel{nullptr};
50  bool createMN();
51  void inform(const QString& text);
52 };
53 
54 #endif // PIVX_QT_MASTERNODEWIZARDDIALOG_H
MasterNodeWizardDialog(WalletModel *walletMode, MNModel *mnModel, QWidget *parent=nullptr)
void inform(const QString &text)
Ui::MasterNodeWizardDialog * ui
QString translate(const char *msg) override
void showEvent(QShowEvent *event) override
CMasternodeConfig::CMasternodeEntry * mnEntry
Interface to PIVX wallet from Qt view code.
Definition: walletmodel.h:109