From: svost Date: Fri, 8 May 2015 16:22:09 +0000 (+0300) Subject: Show QRCode context menu only when USE_QRCODE specified X-Git-Tag: nvc-v0.5.3~10^2 X-Git-Url: https://git.novaco.in/?p=novacoin.git;a=commitdiff_plain;h=ca4b1aef8e92bdc6036c20ed2359f96118dd91a0 Show QRCode context menu only when USE_QRCODE specified --- diff --git a/src/qt/addressbookpage.cpp b/src/qt/addressbookpage.cpp index 5385709..2b32c9f 100644 --- a/src/qt/addressbookpage.cpp +++ b/src/qt/addressbookpage.cpp @@ -65,7 +65,9 @@ AddressBookPage::AddressBookPage(Mode mode, Tabs tab, QWidget *parent) : QAction *copyLabelAction = new QAction(tr("Copy &Label"), this); QAction *copyAddressAction = new QAction(ui->copyToClipboard->text(), this); QAction *editAction = new QAction(tr("&Edit"), this); +#ifdef USE_QRCODE QAction *showQRCodeAction = new QAction(ui->showQRCode->text(), this); +#endif QAction *signMessageAction = new QAction(ui->signMessage->text(), this); QAction *verifyMessageAction = new QAction(ui->verifyMessage->text(), this); deleteAction = new QAction(ui->deleteButton->text(), this); @@ -78,7 +80,9 @@ AddressBookPage::AddressBookPage(Mode mode, Tabs tab, QWidget *parent) : if(tab == SendingTab) contextMenu->addAction(deleteAction); contextMenu->addSeparator(); +#ifdef USE_QRCODE contextMenu->addAction(showQRCodeAction); +#endif if(tab == ReceivingTab) contextMenu->addAction(signMessageAction); else if(tab == SendingTab) @@ -89,7 +93,9 @@ AddressBookPage::AddressBookPage(Mode mode, Tabs tab, QWidget *parent) : connect(copyLabelAction, SIGNAL(triggered()), this, SLOT(onCopyLabelAction())); connect(editAction, SIGNAL(triggered()), this, SLOT(onEditAction())); connect(deleteAction, SIGNAL(triggered()), this, SLOT(on_deleteButton_clicked())); +#ifdef USE_QRCODE connect(showQRCodeAction, SIGNAL(triggered()), this, SLOT(on_showQRCode_clicked())); +#endif connect(signMessageAction, SIGNAL(triggered()), this, SLOT(on_signMessage_clicked())); connect(verifyMessageAction, SIGNAL(triggered()), this, SLOT(on_verifyMessage_clicked()));