mirror of
https://github.com/dashpay/dash.git
synced 2024-12-29 05:49:11 +01:00
527137e3ee
Now it can't be told if this is was a Windows App before. All Mac design principles are fulfilled and some cosmetics have been applied to suit the native look and feel. The biggest change there is the proper use of the Dock icon which takes the role of the Tray icon on Mac. The QDoubleSpinBox improves entering of Bitcoin amounts, no two separate fields are required anymore. All functionality and validation effects have been retained; pressing the comma key will be internally translated to a period to keep it consistent throughout the application and eases entering in countries which use the comma as decimal separator. Additionally, Notificator now supports Growl, Mac's native notification system. This is provided via Apple Script in order to avoid linking to Growl on compile time. Other changes involve encapsulation of Toolbar and Menubar creation, loading of Qt's own translation and some clean up.
38 lines
609 B
C++
38 lines
609 B
C++
#ifndef MACDOCKICONHANDLER_H
|
|
#define MACDOCKICONHANDLER_H
|
|
|
|
#include <QtCore/QObject>
|
|
|
|
class QMenu;
|
|
class QIcon;
|
|
class QWidget;
|
|
class objc_object;
|
|
|
|
class MacDockIconHandler : public QObject
|
|
{
|
|
Q_OBJECT
|
|
public:
|
|
~MacDockIconHandler();
|
|
|
|
QMenu *dockMenu();
|
|
void setIcon(const QIcon &icon);
|
|
|
|
static MacDockIconHandler *instance();
|
|
|
|
void handleDockIconClickEvent();
|
|
|
|
signals:
|
|
void dockIconClicked();
|
|
|
|
public slots:
|
|
|
|
private:
|
|
MacDockIconHandler();
|
|
|
|
objc_object *m_dockIconClickEventHandler;
|
|
QWidget *m_dummyWidget;
|
|
QMenu *m_dockMenu;
|
|
};
|
|
|
|
#endif // MACDOCKICONCLICKHANDLER_H
|