mirror of
https://github.com/wownero/wowlet.git
synced 2026-10-17 15:21:30 +02:00
build: fix -DWITH_SCANNER=Off
This commit is contained in:
@@ -11,9 +11,11 @@
|
||||
|
||||
#include "WalletWizard.h"
|
||||
#include "constants.h"
|
||||
#include "dialog/URDialog.h"
|
||||
#include "libwalletqt/WalletManager.h"
|
||||
|
||||
#ifdef WITH_SCANNER
|
||||
#include "scanner/QrCodeScanDialog.h"
|
||||
#endif
|
||||
|
||||
PageWalletRestoreKeys::PageWalletRestoreKeys(WizardFields *fields, QWidget *parent)
|
||||
: QWizardPage(parent)
|
||||
@@ -43,6 +45,8 @@ PageWalletRestoreKeys::PageWalletRestoreKeys(WizardFields *fields, QWidget *pare
|
||||
|
||||
connect(ui->btnOptions, &QPushButton::clicked, this, &PageWalletRestoreKeys::onOptionsClicked);
|
||||
connect(ui->combo_walletType, &QComboBox::currentTextChanged, this, &PageWalletRestoreKeys::showInputLines);
|
||||
|
||||
#ifdef WITH_SCANNER
|
||||
connect(ui->btn_scanUR, &QPushButton::clicked, [this] {
|
||||
QrCodeScanDialog dialog{this, false};
|
||||
dialog.exec();
|
||||
@@ -66,6 +70,10 @@ PageWalletRestoreKeys::PageWalletRestoreKeys(WizardFields *fields, QWidget *pare
|
||||
m_fields->restoreHeight = doc["restoreHeight"].toInt();
|
||||
m_fields->walletName = doc["walletName"].toString() + "_view_only";
|
||||
});
|
||||
#else
|
||||
ui->btn_scanUR->setEnabled(false);
|
||||
ui->btn_scanUR->setToolTip("Can't scan QR code: Feather was built without webcam scanner support.");
|
||||
#endif
|
||||
}
|
||||
|
||||
void PageWalletRestoreKeys::initializePage() {
|
||||
|
||||
@@ -37,11 +37,6 @@ public:
|
||||
Page_ImportOffline
|
||||
};
|
||||
|
||||
enum Method {
|
||||
UR = 0,
|
||||
FILES,
|
||||
};
|
||||
|
||||
explicit OfflineTxSigningWizard(QWidget *parent, Wallet *wallet, PendingTransaction *tx = nullptr);
|
||||
~OfflineTxSigningWizard() override;
|
||||
|
||||
|
||||
@@ -114,7 +114,7 @@
|
||||
<customwidget>
|
||||
<class>URWidget</class>
|
||||
<extends>QWidget</extends>
|
||||
<header>widgets/URWidget.h</header>
|
||||
<header>qrcode/scanner/URWidget.h</header>
|
||||
<container>1</container>
|
||||
</customwidget>
|
||||
</customwidgets>
|
||||
|
||||
Reference in New Issue
Block a user