chiaki/gui/include/streamwindow.h
2019-08-25 16:38:13 +02:00

55 lines
1.5 KiB
C++

/*
* This file is part of Chiaki.
*
* Chiaki is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Chiaki is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Chiaki. If not, see <https://www.gnu.org/licenses/>.
*/
#ifndef CHIAKI_GUI_STREAMWINDOW_H
#define CHIAKI_GUI_STREAMWINDOW_H
#include <QMainWindow>
#include "streamsession.h"
class QLabel;
class AVOpenGLWidget;
class StreamWindow: public QMainWindow
{
Q_OBJECT
public:
explicit StreamWindow(const StreamSessionConnectInfo &connect_info, QWidget *parent = nullptr);
~StreamWindow() override;
private:
StreamSession *session;
AVOpenGLWidget *av_widget;
void Init(const StreamSessionConnectInfo &connect_info);
protected:
void keyPressEvent(QKeyEvent *event) override;
void keyReleaseEvent(QKeyEvent *event) override;
void closeEvent(QCloseEvent *event) override;
private slots:
void SessionQuit(ChiakiQuitReason reason, const QString &reason_str);
void LoginPINRequested(bool incorrect);
void ToggleFullscreen();
};
#endif // CHIAKI_GUI_STREAMWINDOW_H