Merge pull request #6206 from spycrab/qt_fix_bs

Qt: Fix blackscreen
This commit is contained in:
Stenzek 2017-11-20 02:55:41 +10:00 committed by GitHub
commit 175db0d817
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -15,8 +15,14 @@ RenderWidget::RenderWidget(QWidget* parent) : QWidget(parent)
setAttribute(Qt::WA_NoSystemBackground, true); setAttribute(Qt::WA_NoSystemBackground, true);
connect(Host::GetInstance(), &Host::RequestTitle, this, &RenderWidget::setWindowTitle); connect(Host::GetInstance(), &Host::RequestTitle, this, &RenderWidget::setWindowTitle);
connect(this, &RenderWidget::StateChanged, Host::GetInstance(), &Host::SetRenderFullscreen);
connect(this, &RenderWidget::HandleChanged, Host::GetInstance(), &Host::SetRenderHandle); // We have to use Qt::DirectConnection here because we don't want those signals to get queued
// (which results in them not getting called)
connect(this, &RenderWidget::StateChanged, Host::GetInstance(), &Host::SetRenderFullscreen,
Qt::DirectConnection);
connect(this, &RenderWidget::HandleChanged, Host::GetInstance(), &Host::SetRenderHandle,
Qt::DirectConnection);
emit HandleChanged((void*)winId()); emit HandleChanged((void*)winId());
m_mouse_timer = new QTimer(this); m_mouse_timer = new QTimer(this);