Add CHIAKI_GUI_ENABLE_QT_GAMEPAD option

This commit is contained in:
Florian Märkl 2019-07-10 09:41:11 +02:00
commit 3f76782b6c
No known key found for this signature in database
GPG key ID: 125BC8A5A6A1E857
3 changed files with 64 additions and 30 deletions

View file

@ -25,7 +25,10 @@
#include <chiaki/session.h>
#if CHIAKI_GUI_ENABLE_QT_GAMEPAD
class QGamepad;
#endif
class QAudioOutput;
class QIODevice;
@ -38,7 +41,9 @@ class StreamSession : public QObject
private:
ChiakiSession session;
#if CHIAKI_GUI_ENABLE_QT_GAMEPAD
QGamepad *gamepad;
#endif
VideoDecoder video_decoder;
@ -52,14 +57,18 @@ class StreamSession : public QObject
explicit StreamSession(const QString &host, const QString &registkey, const QString &ostype, const QString &auth, const QString &morning, const QString &did, QObject *parent = nullptr);
~StreamSession();
#if CHIAKI_GUI_ENABLE_QT_GAMEPAD
QGamepad *GetGamepad() { return gamepad; }
#endif
VideoDecoder *GetVideoDecoder() { return &video_decoder; }
signals:
void CurrentImageUpdated();
private slots:
#if CHIAKI_GUI_ENABLE_QT_GAMEPAD
void UpdateGamepads();
#endif
void SendFeedbackState();
};