Make static
This commit is contained in:
@@ -53,13 +53,13 @@ class GlobalShortcut : public QObject, QAbstractNativeEventFilter {
|
||||
|
||||
private:
|
||||
|
||||
void activateShortcut(quint32 native_key, quint32 native_mods);
|
||||
static void activateShortcut(quint32 native_key, quint32 native_mods);
|
||||
|
||||
quint32 nativeModifiers(Qt::KeyboardModifiers qt_mods);
|
||||
quint32 nativeKeycode(Qt::Key qt_keycode);
|
||||
static quint32 nativeModifiers(Qt::KeyboardModifiers qt_mods);
|
||||
static quint32 nativeKeycode(Qt::Key qt_keycode);
|
||||
|
||||
bool registerShortcut(quint32 native_key, quint32 native_mods);
|
||||
bool unregisterShortcut(quint32 native_key, quint32 native_mods);
|
||||
static bool registerShortcut(quint32 native_key, quint32 native_mods);
|
||||
static bool unregisterShortcut(quint32 native_key, quint32 native_mods);
|
||||
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
|
||||
bool nativeEventFilter(const QByteArray &eventtype, void *message, qintptr *result) override;
|
||||
|
||||
@@ -179,7 +179,7 @@ bool GlobalShortcutsManager::IsMateAvailable() const {
|
||||
|
||||
}
|
||||
|
||||
bool GlobalShortcutsManager::IsX11Available() const {
|
||||
bool GlobalShortcutsManager::IsX11Available() {
|
||||
|
||||
return QApplication::platformName() == "xcb";
|
||||
|
||||
@@ -212,7 +212,7 @@ void GlobalShortcutsManager::Unregister() {
|
||||
|
||||
}
|
||||
|
||||
bool GlobalShortcutsManager::IsMacAccessibilityEnabled() const {
|
||||
bool GlobalShortcutsManager::IsMacAccessibilityEnabled() {
|
||||
#ifdef Q_OS_MACOS
|
||||
if (system_backend_) return qobject_cast<GlobalShortcutsBackendMacOS*>(system_backend_)->IsAccessibilityEnabled();
|
||||
else return false;
|
||||
|
||||
@@ -52,10 +52,10 @@ class GlobalShortcutsManager : public QWidget {
|
||||
|
||||
QMap<QString, Shortcut> shortcuts() const { return shortcuts_; }
|
||||
bool IsKdeAvailable() const;
|
||||
bool IsX11Available() const;
|
||||
static bool IsX11Available() ;
|
||||
bool IsGnomeAvailable() const;
|
||||
bool IsMateAvailable() const;
|
||||
bool IsMacAccessibilityEnabled() const;
|
||||
static bool IsMacAccessibilityEnabled() ;
|
||||
|
||||
public slots:
|
||||
void ReloadSettings();
|
||||
|
||||
Reference in New Issue
Block a user