2018-02-27 18:06:05 +01:00
|
|
|
#ifndef MAC_STARTUP_H
|
|
|
|
#define MAC_STARTUP_H
|
|
|
|
|
|
|
|
#include "config.h"
|
|
|
|
|
2018-05-01 00:41:33 +02:00
|
|
|
#include <QString>
|
2018-02-27 18:06:05 +01:00
|
|
|
#include <QKeySequence>
|
|
|
|
|
|
|
|
class QObject;
|
|
|
|
class QWidget;
|
|
|
|
|
2019-01-02 00:32:36 +01:00
|
|
|
class GlobalShortcutBackendMacOS;
|
2018-05-01 00:41:33 +02:00
|
|
|
|
2018-02-27 18:06:05 +01:00
|
|
|
class PlatformInterface {
|
|
|
|
public:
|
|
|
|
// Called when the application should show itself.
|
|
|
|
virtual void Activate() = 0;
|
2018-05-01 00:41:33 +02:00
|
|
|
virtual bool LoadUrl(const QString &url) = 0;
|
2018-02-27 18:06:05 +01:00
|
|
|
|
|
|
|
virtual ~PlatformInterface() {}
|
|
|
|
};
|
|
|
|
|
|
|
|
namespace mac {
|
|
|
|
|
|
|
|
void MacMain();
|
2019-01-02 00:32:36 +01:00
|
|
|
void SetShortcutHandler(GlobalShortcutBackendMacOS *handler);
|
2018-05-01 00:41:33 +02:00
|
|
|
void SetApplicationHandler(PlatformInterface *handler);
|
2018-02-27 18:06:05 +01:00
|
|
|
void CheckForUpdates();
|
|
|
|
|
|
|
|
QString GetBundlePath();
|
|
|
|
QString GetResourcesPath();
|
|
|
|
QString GetApplicationSupportPath();
|
|
|
|
QString GetMusicDirectory();
|
|
|
|
|
2018-05-01 00:41:33 +02:00
|
|
|
void EnableFullScreen(const QWidget &main_window);
|
2018-02-27 18:06:05 +01:00
|
|
|
|
|
|
|
} // namespace mac
|
|
|
|
|
|
|
|
#endif
|