diff --git a/Source/Core/DolphinQt/RenderWidget.cpp b/Source/Core/DolphinQt/RenderWidget.cpp index 3fbb24fb63..14cc33fae7 100644 --- a/Source/Core/DolphinQt/RenderWidget.cpp +++ b/Source/Core/DolphinQt/RenderWidget.cpp @@ -58,9 +58,6 @@ RenderWidget::RenderWidget(QWidget* parent) : QWidget(parent) }); connect(&Settings::Instance(), &Settings::EmulationStateChanged, this, [this](Core::State state) { - // Stop filling the background once emulation starts, but fill it until then (Bug 10958) - SetFillBackground(Config::Get(Config::MAIN_RENDER_TO_MAIN) && - state == Core::State::Uninitialized); if (state == Core::State::Running) SetImGuiKeyMap(); }); @@ -91,21 +88,12 @@ RenderWidget::RenderWidget(QWidget* parent) : QWidget(parent) // We need a native window to render into. setAttribute(Qt::WA_NativeWindow); - - SetFillBackground(true); -} - -void RenderWidget::SetFillBackground(bool fill) -{ - setAutoFillBackground(fill); - setAttribute(Qt::WA_OpaquePaintEvent, !fill); - setAttribute(Qt::WA_NoSystemBackground, !fill); - setAttribute(Qt::WA_PaintOnScreen, !fill); + setAttribute(Qt::WA_PaintOnScreen); } QPaintEngine* RenderWidget::paintEngine() const { - return autoFillBackground() ? QWidget::paintEngine() : nullptr; + return nullptr; } void RenderWidget::dragEnterEvent(QDragEnterEvent* event) @@ -178,8 +166,6 @@ bool RenderWidget::event(QEvent* event) switch (event->type()) { - case QEvent::Paint: - return !autoFillBackground(); case QEvent::KeyPress: { QKeyEvent* ke = static_cast(event); diff --git a/Source/Core/DolphinQt/RenderWidget.h b/Source/Core/DolphinQt/RenderWidget.h index 818e9209ab..650ba2d1dc 100644 --- a/Source/Core/DolphinQt/RenderWidget.h +++ b/Source/Core/DolphinQt/RenderWidget.h @@ -33,7 +33,6 @@ private: void HandleCursorTimer(); void OnHideCursorChanged(); void OnKeepOnTopChanged(bool top); - void SetFillBackground(bool fill); void OnFreeLookMouseMove(QMouseEvent* event); void PassEventToImGui(const QEvent* event); void SetImGuiKeyMap();