-
Notifications
You must be signed in to change notification settings - Fork 375
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge #14123: gui: Add GUIUtil::bringToFront
0a656f8 qt: All tray menu actions call showNormalIfMinimized (João Barbosa) 6fc21ac qt: Use GUIUtil::bringToFront where possible (João Barbosa) 5796671 qt: Add GUIUtil::bringToFront (João Barbosa) 6b1d297 Remove obj_c for macOS Dock icon menu (Hennadii Stepanov) 2464925 Use Qt signal for macOS Dock icon click event (Hennadii Stepanov) 53bb6be Remove obj_c for macOS Dock icon setting (Hennadii Stepanov) Pull request description: The sequence `show -> raise -> activateWindow` is factored out to the new function `GUIUtil::bringToFront` where a macOS fix is added in order to fix #13829. Also included: - simplification of `BitcoinGUI::showNormalIfMinimized` - simplified some connections to `BitcoinGUI::showNormalIfMinimized` - added missing connections to `BitcoinGUI::showNormalIfMinimized`. Tree-SHA512: a8e301aebc359aa353821e2af352ae356f44555724921b01da907e128653ef9dc55d8764a1bff72a579e5ff96df8a681f6804bfe83acba441da92fedff974a55
- Loading branch information
Showing
7 changed files
with
76 additions
and
159 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,44 +1,27 @@ | ||
// Copyright (c) 2011-2015 The Bitcoin Core developers | ||
// Copyright (c) 2011-2018 The Bitcoin Core developers | ||
// Distributed under the MIT software license, see the accompanying | ||
// file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||
|
||
#ifndef BITCOIN_QT_MACDOCKICONHANDLER_H | ||
#define BITCOIN_QT_MACDOCKICONHANDLER_H | ||
|
||
#include <QMainWindow> | ||
#include <QObject> | ||
|
||
QT_BEGIN_NAMESPACE | ||
class QIcon; | ||
class QMenu; | ||
class QWidget; | ||
QT_END_NAMESPACE | ||
|
||
/** Macintosh-specific dock icon handler. | ||
/** macOS-specific Dock icon handler. | ||
*/ | ||
class MacDockIconHandler : public QObject | ||
{ | ||
Q_OBJECT | ||
|
||
public: | ||
~MacDockIconHandler(); | ||
|
||
QMenu *dockMenu(); | ||
void setIcon(const QIcon &icon); | ||
void setMainWindow(QMainWindow *window); | ||
static MacDockIconHandler *instance(); | ||
static void cleanup(); | ||
void handleDockIconClickEvent(); | ||
|
||
Q_SIGNALS: | ||
void dockIconClicked(); | ||
|
||
private: | ||
MacDockIconHandler(); | ||
|
||
QWidget *m_dummyWidget; | ||
QMenu *m_dockMenu; | ||
QMainWindow *mainWindow; | ||
}; | ||
|
||
#endif // BITCOIN_QT_MACDOCKICONHANDLER_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.