diff options
| author | Wladimir J. van der Laan <[email protected]> | 2013-03-30 22:51:43 -0700 |
|---|---|---|
| committer | Wladimir J. van der Laan <[email protected]> | 2013-03-30 22:51:43 -0700 |
| commit | 9d8d85920a9a7544ab05542d46b68ffb3c2741fa (patch) | |
| tree | 3ffdac3c1900268c006ef5be23d30b5738ac84d9 /src | |
| parent | Merge pull request #2361 from L2G/font-tweak (diff) | |
| parent | Bitcoin-Qt: ensure createTrayIconMenu() is always called on Mac (diff) | |
| download | discoin-9d8d85920a9a7544ab05542d46b68ffb3c2741fa.tar.xz discoin-9d8d85920a9a7544ab05542d46b68ffb3c2741fa.zip | |
Merge pull request #2386 from Diapolo/Mac_GUI
Bitcoin-Qt: ensure createTrayIconMenu() is always called on Mac
Diffstat (limited to 'src')
| -rw-r--r-- | src/qt/bitcoingui.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/qt/bitcoingui.cpp b/src/qt/bitcoingui.cpp index eff8e667f..a48581c6a 100644 --- a/src/qt/bitcoingui.cpp +++ b/src/qt/bitcoingui.cpp @@ -326,8 +326,7 @@ void BitcoinGUI::setClientModel(ClientModel *clientModel) // Create system tray menu (or setup the dock menu) that late to prevent users from calling actions, // while the client has not yet fully loaded - if(trayIcon) - createTrayIconMenu(); + createTrayIconMenu(); // Keep up to date with client setNumConnections(clientModel->getNumConnections()); @@ -375,6 +374,10 @@ void BitcoinGUI::createTrayIconMenu() { QMenu *trayIconMenu; #ifndef Q_OS_MAC + // return if trayIcon is unset (only on non-Mac OSes) + if (!trayIcon) + return; + trayIconMenu = new QMenu(this); trayIcon->setContextMenu(trayIconMenu); |