1515#include < qt/openuridialog.h>
1616#include < qt/optionsdialog.h>
1717#include < qt/optionsmodel.h>
18- #include < qt/platformstyle.h>
1918#include < qt/rpcconsole.h>
2019#include < qt/utilitydialog.h>
2120
@@ -72,7 +71,7 @@ const std::string BitcoinGUI::DEFAULT_UIPLATFORM =
7271#endif
7372 ;
7473
75- BitcoinGUI::BitcoinGUI (const PlatformStyle *_platformStyle, const NetworkStyle * networkStyle, QWidget * parent) :
74+ BitcoinGUI::BitcoinGUI (const NetworkStyle* networkStyle, QWidget* parent) :
7675 QMainWindow(parent),
7776 enableWallet(false ),
7877 clientModel(0 ),
@@ -122,8 +121,7 @@ BitcoinGUI::BitcoinGUI(const PlatformStyle *_platformStyle, const NetworkStyle *
122121 modalOverlay(0 ),
123122 tabGroup(0 ),
124123 prevBlocks(0 ),
125- spinnerFrame(0 ),
126- platformStyle(_platformStyle)
124+ spinnerFrame(0 )
127125{
128126 QSettings settings;
129127 if (!restoreGeometry (settings.value (" MainWindowGeometry" ).toByteArray ())) {
@@ -148,13 +146,13 @@ BitcoinGUI::BitcoinGUI(const PlatformStyle *_platformStyle, const NetworkStyle *
148146 setWindowIcon (networkStyle->getTrayAndWindowIcon ());
149147 setWindowTitle (windowTitle);
150148
151- rpcConsole = new RPCConsole (_platformStyle, this );
149+ rpcConsole = new RPCConsole (this );
152150 helpMessageDialog = new HelpMessageDialog (this , HelpMessageDialog::cmdline);
153151#ifdef ENABLE_WALLET
154152 if (enableWallet)
155153 {
156154 /* * Create wallet frame*/
157- walletFrame = new WalletFrame (_platformStyle, this );
155+ walletFrame = new WalletFrame (this );
158156 } else
159157#endif // ENABLE_WALLET
160158 {
@@ -193,7 +191,7 @@ BitcoinGUI::BitcoinGUI(const PlatformStyle *_platformStyle, const NetworkStyle *
193191 QHBoxLayout *frameBlocksLayout = new QHBoxLayout (frameBlocks);
194192 frameBlocksLayout->setContentsMargins (3 ,0 ,3 ,0 );
195193 frameBlocksLayout->setSpacing (3 );
196- unitDisplayControl = new UnitDisplayStatusBarControl (platformStyle );
194+ unitDisplayControl = new UnitDisplayStatusBarControl ();
197195 labelWalletEncryptionIcon = new QLabel ();
198196 labelWalletHDStatusIcon = new QLabel ();
199197 labelConnectionsIcon = new GUIUtil::ClickableLabel ();
@@ -311,7 +309,7 @@ void BitcoinGUI::createActions()
311309#endif
312310 tabGroup->addButton (sendCoinsAction);
313311
314- sendCoinsMenuAction = new QAction (QIcon ( " :/icons/send " ), sendCoinsAction->text (), this );
312+ sendCoinsMenuAction = new QAction (sendCoinsAction->text (), this );
315313 sendCoinsMenuAction->setStatusTip (sendCoinsAction->statusTip ());
316314 sendCoinsMenuAction->setToolTip (sendCoinsMenuAction->statusTip ());
317315
@@ -327,7 +325,7 @@ void BitcoinGUI::createActions()
327325#endif
328326 tabGroup->addButton (privateSendCoinsAction);
329327
330- privateSendCoinsMenuAction = new QAction (QIcon ( " :/icons/send " ), privateSendCoinsAction->text (), this );
328+ privateSendCoinsMenuAction = new QAction (privateSendCoinsAction->text (), this );
331329 privateSendCoinsMenuAction->setStatusTip (privateSendCoinsAction->statusTip ());
332330 privateSendCoinsMenuAction->setToolTip (privateSendCoinsMenuAction->statusTip ());
333331
@@ -343,7 +341,7 @@ void BitcoinGUI::createActions()
343341#endif
344342 tabGroup->addButton (receiveCoinsAction);
345343
346- receiveCoinsMenuAction = new QAction (QIcon ( " :/icons/receiving_addresses " ), receiveCoinsAction->text (), this );
344+ receiveCoinsMenuAction = new QAction (receiveCoinsAction->text (), this );
347345 receiveCoinsMenuAction->setStatusTip (receiveCoinsAction->statusTip ());
348346 receiveCoinsMenuAction->setToolTip (receiveCoinsMenuAction->statusTip ());
349347
@@ -403,54 +401,54 @@ void BitcoinGUI::createActions()
403401 connect (tabGroup, SIGNAL (buttonToggled (QAbstractButton *, bool )), this , SLOT (highlightTabButton (QAbstractButton *, bool )));
404402#endif // ENABLE_WALLET
405403
406- quitAction = new QAction (QIcon ( " :/icons/quit " ), tr (" E&xit" ), this );
404+ quitAction = new QAction (tr (" E&xit" ), this );
407405 quitAction->setStatusTip (tr (" Quit application" ));
408406 quitAction->setShortcut (QKeySequence (Qt::CTRL + Qt::Key_Q));
409407 quitAction->setMenuRole (QAction::QuitRole);
410- aboutAction = new QAction (QIcon ( " :/icons/about " ), tr (" &About %1" ).arg (tr (PACKAGE_NAME)), this );
408+ aboutAction = new QAction (tr (" &About %1" ).arg (tr (PACKAGE_NAME)), this );
411409 aboutAction->setStatusTip (tr (" Show information about Dash Core" ));
412410 aboutAction->setMenuRole (QAction::AboutRole);
413411 aboutAction->setEnabled (false );
414- aboutQtAction = new QAction (QIcon ( " :/icons/about_qt " ), tr (" About &Qt" ), this );
412+ aboutQtAction = new QAction (tr (" About &Qt" ), this );
415413 aboutQtAction->setStatusTip (tr (" Show information about Qt" ));
416414 aboutQtAction->setMenuRole (QAction::AboutQtRole);
417- optionsAction = new QAction (QIcon ( " :/icons/options " ), tr (" &Options..." ), this );
415+ optionsAction = new QAction (tr (" &Options..." ), this );
418416 optionsAction->setStatusTip (tr (" Modify configuration options for %1" ).arg (tr (PACKAGE_NAME)));
419417 optionsAction->setMenuRole (QAction::PreferencesRole);
420418 optionsAction->setEnabled (false );
421- toggleHideAction = new QAction (QIcon ( " :/icons/about " ), tr (" &Show / Hide" ), this );
419+ toggleHideAction = new QAction (tr (" &Show / Hide" ), this );
422420 toggleHideAction->setStatusTip (tr (" Show or hide the main Window" ));
423421
424- encryptWalletAction = new QAction (QIcon ( " :/icons/lock_closed " ), tr (" &Encrypt Wallet..." ), this );
422+ encryptWalletAction = new QAction (tr (" &Encrypt Wallet..." ), this );
425423 encryptWalletAction->setStatusTip (tr (" Encrypt the private keys that belong to your wallet" ));
426424 encryptWalletAction->setCheckable (true );
427- backupWalletAction = new QAction (QIcon ( " :/icons/filesave " ), tr (" &Backup Wallet..." ), this );
425+ backupWalletAction = new QAction (tr (" &Backup Wallet..." ), this );
428426 backupWalletAction->setStatusTip (tr (" Backup wallet to another location" ));
429- changePassphraseAction = new QAction (QIcon ( " :/icons/key " ), tr (" &Change Passphrase..." ), this );
427+ changePassphraseAction = new QAction (tr (" &Change Passphrase..." ), this );
430428 changePassphraseAction->setStatusTip (tr (" Change the passphrase used for wallet encryption" ));
431429 unlockWalletAction = new QAction (tr (" &Unlock Wallet..." ), this );
432430 unlockWalletAction->setToolTip (tr (" Unlock wallet" ));
433431 lockWalletAction = new QAction (tr (" &Lock Wallet" ), this );
434- signMessageAction = new QAction (QIcon ( " :/icons/edit " ), tr (" Sign &message..." ), this );
432+ signMessageAction = new QAction (tr (" Sign &message..." ), this );
435433 signMessageAction->setStatusTip (tr (" Sign messages with your Dash addresses to prove you own them" ));
436- verifyMessageAction = new QAction (QIcon ( " :/icons/transaction_0 " ), tr (" &Verify message..." ), this );
434+ verifyMessageAction = new QAction (tr (" &Verify message..." ), this );
437435 verifyMessageAction->setStatusTip (tr (" Verify messages to ensure they were signed with specified Dash addresses" ));
438436
439- openInfoAction = new QAction (QApplication::style ()-> standardIcon (QStyle::SP_MessageBoxInformation), tr (" &Information" ), this );
437+ openInfoAction = new QAction (tr (" &Information" ), this );
440438 openInfoAction->setStatusTip (tr (" Show diagnostic information" ));
441- openRPCConsoleAction = new QAction (QIcon ( " :/icons/debugwindow " ), tr (" &Debug console" ), this );
439+ openRPCConsoleAction = new QAction (tr (" &Debug console" ), this );
442440 openRPCConsoleAction->setStatusTip (tr (" Open debugging console" ));
443- openGraphAction = new QAction (QIcon ( " :/icons/connect_4 " ), tr (" &Network Monitor" ), this );
441+ openGraphAction = new QAction (tr (" &Network Monitor" ), this );
444442 openGraphAction->setStatusTip (tr (" Show network monitor" ));
445- openPeersAction = new QAction (QIcon ( " :/icons/connect_4 " ), tr (" &Peers list" ), this );
443+ openPeersAction = new QAction (tr (" &Peers list" ), this );
446444 openPeersAction->setStatusTip (tr (" Show peers info" ));
447- openRepairAction = new QAction (QIcon ( " :/icons/options " ), tr (" Wallet &Repair" ), this );
445+ openRepairAction = new QAction (tr (" Wallet &Repair" ), this );
448446 openRepairAction->setStatusTip (tr (" Show wallet repair options" ));
449- openConfEditorAction = new QAction (QIcon ( " :/icons/edit " ), tr (" Open Wallet &Configuration File" ), this );
447+ openConfEditorAction = new QAction (tr (" Open Wallet &Configuration File" ), this );
450448 openConfEditorAction->setStatusTip (tr (" Open configuration file" ));
451449 // override TextHeuristicRole set by default which confuses this action with application settings
452450 openConfEditorAction->setMenuRole (QAction::NoRole);
453- showBackupsAction = new QAction (QIcon ( " :/icons/browse " ), tr (" Show Automatic &Backups" ), this );
451+ showBackupsAction = new QAction (tr (" Show Automatic &Backups" ), this );
454452 showBackupsAction->setStatusTip (tr (" Show automatically created wallet backups" ));
455453 // initially disable the debug window menu items
456454 openInfoAction->setEnabled (false );
@@ -459,19 +457,19 @@ void BitcoinGUI::createActions()
459457 openPeersAction->setEnabled (false );
460458 openRepairAction->setEnabled (false );
461459
462- usedSendingAddressesAction = new QAction (QIcon ( " :/icons/address-book " ), tr (" &Sending addresses..." ), this );
460+ usedSendingAddressesAction = new QAction (tr (" &Sending addresses..." ), this );
463461 usedSendingAddressesAction->setStatusTip (tr (" Show the list of used sending addresses and labels" ));
464- usedReceivingAddressesAction = new QAction (QIcon ( " :/icons/address-book " ), tr (" &Receiving addresses..." ), this );
462+ usedReceivingAddressesAction = new QAction (tr (" &Receiving addresses..." ), this );
465463 usedReceivingAddressesAction->setStatusTip (tr (" Show the list of used receiving addresses and labels" ));
466464
467- openAction = new QAction (QApplication::style ()-> standardIcon (QStyle::SP_DirOpenIcon), tr (" Open &URI..." ), this );
465+ openAction = new QAction (tr (" Open &URI..." ), this );
468466 openAction->setStatusTip (tr (" Open a dash: URI or payment request" ));
469467
470- showHelpMessageAction = new QAction (QApplication::style ()-> standardIcon (QStyle::SP_MessageBoxInformation), tr (" &Command-line options" ), this );
468+ showHelpMessageAction = new QAction (tr (" &Command-line options" ), this );
471469 showHelpMessageAction->setMenuRole (QAction::NoRole);
472470 showHelpMessageAction->setStatusTip (tr (" Show the %1 help message to get a list with possible Dash command-line options" ).arg (tr (PACKAGE_NAME)));
473471
474- showPrivateSendHelpAction = new QAction (QApplication::style ()-> standardIcon (QStyle::SP_MessageBoxInformation), tr (" &PrivateSend information" ), this );
472+ showPrivateSendHelpAction = new QAction (tr (" &PrivateSend information" ), this );
475473 showPrivateSendHelpAction->setMenuRole (QAction::NoRole);
476474 showPrivateSendHelpAction->setStatusTip (tr (" Show the PrivateSend basic information" ));
477475
@@ -697,13 +695,13 @@ void BitcoinGUI::setClientModel(ClientModel *_clientModel)
697695 }
698696#endif // ENABLE_WALLET
699697 unitDisplayControl->setOptionsModel (_clientModel->getOptionsModel ());
700-
698+
701699 OptionsModel* optionsModel = _clientModel->getOptionsModel ();
702700 if (optionsModel)
703701 {
704702 // be aware of the tray icon disable state change reported by the OptionsModel object.
705703 connect (optionsModel,SIGNAL (hideTrayIconChanged (bool )),this ,SLOT (setTrayIconVisible (bool )));
706-
704+
707705 // initialize the disable state of the tray icon with the current value in the model.
708706 setTrayIconVisible (optionsModel->getHideTrayIcon ());
709707 }
@@ -1022,7 +1020,7 @@ void BitcoinGUI::updateNetworkState()
10221020 icon = " :/icons/network_disabled" ;
10231021 }
10241022
1025- labelConnectionsIcon->setPixmap (platformStyle-> SingleColorIcon (icon).pixmap (STATUSBAR_ICONSIZE,STATUSBAR_ICONSIZE));
1023+ labelConnectionsIcon->setPixmap (QIcon (icon).pixmap (STATUSBAR_ICONSIZE, STATUSBAR_ICONSIZE));
10261024}
10271025
10281026void BitcoinGUI::setNumConnections (int count)
@@ -1140,7 +1138,7 @@ void BitcoinGUI::setNumBlocks(int count, const QDateTime& blockDate, double nVer
11401138 tooltip = tr (" Catching up..." ) + QString (" <br>" ) + tooltip;
11411139 if (count != prevBlocks)
11421140 {
1143- labelBlocksIcon->setPixmap (platformStyle-> SingleColorIcon (QString (
1141+ labelBlocksIcon->setPixmap (QIcon (QString (
11441142 " :/movies/spinner-%1" ).arg (spinnerFrame, 3 , 10 , QChar (' 0' )))
11451143 .pixmap (STATUSBAR_ICONSIZE, STATUSBAR_ICONSIZE));
11461144 spinnerFrame = (spinnerFrame + 1 ) % SPINNER_FRAMES;
@@ -1199,7 +1197,7 @@ void BitcoinGUI::setAdditionalDataSyncProgress(double nSyncProgress)
11991197 labelBlocksIcon->setPixmap (QIcon (" :/icons/synced" ).pixmap (STATUSBAR_ICONSIZE, STATUSBAR_ICONSIZE));
12001198 } else {
12011199
1202- labelBlocksIcon->setPixmap (platformStyle-> SingleColorIcon (QString (
1200+ labelBlocksIcon->setPixmap (QIcon (QString (
12031201 " :/movies/spinner-%1" ).arg (spinnerFrame, 3 , 10 , QChar (' 0' )))
12041202 .pixmap (STATUSBAR_ICONSIZE, STATUSBAR_ICONSIZE));
12051203 spinnerFrame = (spinnerFrame + 1 ) % SPINNER_FRAMES;
@@ -1472,7 +1470,7 @@ bool BitcoinGUI::handlePaymentRequest(const SendCoinsRecipient& recipient)
14721470
14731471void BitcoinGUI::setHDStatus (int hdEnabled)
14741472{
1475- labelWalletHDStatusIcon->setPixmap (platformStyle-> SingleColorIcon (hdEnabled ? " :/icons/hd_enabled" : " :/icons/hd_disabled" ).pixmap (STATUSBAR_ICONSIZE,STATUSBAR_ICONSIZE));
1473+ labelWalletHDStatusIcon->setPixmap (QIcon (hdEnabled ? " :/icons/hd_enabled" : " :/icons/hd_disabled" ).pixmap (STATUSBAR_ICONSIZE, STATUSBAR_ICONSIZE));
14761474 labelWalletHDStatusIcon->setToolTip (hdEnabled ? tr (" HD key generation is <b>enabled</b>" ) : tr (" HD key generation is <b>disabled</b>" ));
14771475
14781476 // eventually disable the QLabel to set its opacity to 50%
@@ -1648,7 +1646,7 @@ void BitcoinGUI::handleRestart(QStringList args)
16481646 Q_EMIT requestedRestart (args);
16491647}
16501648
1651- UnitDisplayStatusBarControl::UnitDisplayStatusBarControl (const PlatformStyle *platformStyle ) :
1649+ UnitDisplayStatusBarControl::UnitDisplayStatusBarControl () :
16521650 optionsModel(0 ),
16531651 menu(0 )
16541652{
0 commit comments