2019-03-23 19:05:08 +00:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <QObject>
|
|
|
|
#include <QRect>
|
|
|
|
|
|
|
|
class SystemProperties : public QObject
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
public:
|
|
|
|
SystemProperties();
|
|
|
|
|
|
|
|
Q_PROPERTY(bool hasHardwareAcceleration MEMBER hasHardwareAcceleration CONSTANT)
|
2020-02-09 19:35:05 +00:00
|
|
|
Q_PROPERTY(bool rendererAlwaysFullScreen MEMBER rendererAlwaysFullScreen CONSTANT)
|
2019-03-23 19:05:08 +00:00
|
|
|
Q_PROPERTY(bool isRunningWayland MEMBER isRunningWayland CONSTANT)
|
2019-04-22 01:31:11 +00:00
|
|
|
Q_PROPERTY(bool isRunningXWayland MEMBER isRunningXWayland CONSTANT)
|
2019-03-23 19:05:08 +00:00
|
|
|
Q_PROPERTY(bool isWow64 MEMBER isWow64 CONSTANT)
|
2020-02-09 05:31:04 +00:00
|
|
|
Q_PROPERTY(bool hasWindowManager MEMBER hasWindowManager CONSTANT)
|
2019-03-23 19:05:08 +00:00
|
|
|
Q_PROPERTY(bool hasBrowser MEMBER hasBrowser CONSTANT)
|
2019-06-30 00:40:30 +00:00
|
|
|
Q_PROPERTY(bool hasDiscordIntegration MEMBER hasDiscordIntegration CONSTANT)
|
2019-03-23 19:05:08 +00:00
|
|
|
Q_PROPERTY(QString unmappedGamepads MEMBER unmappedGamepads NOTIFY unmappedGamepadsChanged)
|
|
|
|
Q_PROPERTY(int maximumStreamingFrameRate MEMBER maximumStreamingFrameRate CONSTANT)
|
2020-02-23 08:43:43 +00:00
|
|
|
Q_PROPERTY(QSize maximumResolution MEMBER maximumResolution CONSTANT)
|
2020-05-10 05:20:39 +00:00
|
|
|
Q_PROPERTY(QString versionString MEMBER versionString CONSTANT)
|
2019-03-23 19:05:08 +00:00
|
|
|
|
|
|
|
Q_INVOKABLE QRect getDesktopResolution(int displayIndex);
|
|
|
|
Q_INVOKABLE QRect getNativeResolution(int displayIndex);
|
|
|
|
|
|
|
|
signals:
|
|
|
|
void unmappedGamepadsChanged();
|
|
|
|
|
|
|
|
private:
|
|
|
|
void querySdlVideoInfo();
|
|
|
|
|
|
|
|
bool hasHardwareAcceleration;
|
2020-02-09 19:35:05 +00:00
|
|
|
bool rendererAlwaysFullScreen;
|
2019-03-23 19:05:08 +00:00
|
|
|
bool isRunningWayland;
|
2019-04-22 01:31:11 +00:00
|
|
|
bool isRunningXWayland;
|
2019-03-23 19:05:08 +00:00
|
|
|
bool isWow64;
|
2020-02-09 05:31:04 +00:00
|
|
|
bool hasWindowManager;
|
2019-03-23 19:05:08 +00:00
|
|
|
bool hasBrowser;
|
2019-06-30 00:40:30 +00:00
|
|
|
bool hasDiscordIntegration;
|
2019-03-23 19:05:08 +00:00
|
|
|
QString unmappedGamepads;
|
|
|
|
int maximumStreamingFrameRate;
|
2020-02-23 08:43:43 +00:00
|
|
|
QSize maximumResolution;
|
2019-03-23 19:05:08 +00:00
|
|
|
QList<QRect> monitorDesktopResolutions;
|
|
|
|
QList<QRect> monitorNativeResolutions;
|
2020-05-10 05:20:39 +00:00
|
|
|
QString versionString;
|
2019-03-23 19:05:08 +00:00
|
|
|
};
|
|
|
|
|