mirror of https://github.com/mgba-emu/mgba.git
Qt: Fix GL display not updating while paused
This commit is contained in:
parent
c0120cd586
commit
ca8559549c
|
@ -64,7 +64,6 @@ DisplayGL::DisplayGL(const QSurfaceFormat& format, QWidget* parent)
|
|||
}
|
||||
|
||||
m_painter = new PainterGL(windowHandle(), m_gl, forceVersion);
|
||||
setUpdatesEnabled(false); // Prevent paint events, which can cause race conditions
|
||||
}
|
||||
|
||||
DisplayGL::~DisplayGL() {
|
||||
|
@ -475,8 +474,6 @@ void PainterGL::swap() {
|
|||
}
|
||||
if (!m_queue.isEmpty()) {
|
||||
QMetaObject::invokeMethod(this, "draw", Qt::QueuedConnection);
|
||||
} else {
|
||||
m_swapTimer.start();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -60,7 +60,7 @@ public slots:
|
|||
void resizeContext() override;
|
||||
|
||||
protected:
|
||||
virtual void paintEvent(QPaintEvent*) override {}
|
||||
virtual void paintEvent(QPaintEvent*) override { forceDraw(); }
|
||||
virtual void resizeEvent(QResizeEvent*) override;
|
||||
|
||||
private:
|
||||
|
|
Loading…
Reference in New Issue