From 3318e97f29025e5c30918b4fc2b70782950cdbf0 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Tue, 16 Apr 2019 23:49:24 -0400 Subject: [PATCH 1/3] yuzu/bootmanager: Resolve constructor initializer list warnings Resolves -Wreorder warnings. These will automatically be initialized to nullptr anyways, so these were redundant. --- src/yuzu/bootmanager.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/yuzu/bootmanager.cpp b/src/yuzu/bootmanager.cpp index c29f2d2dc1..a197831d8b 100644 --- a/src/yuzu/bootmanager.cpp +++ b/src/yuzu/bootmanager.cpp @@ -186,8 +186,7 @@ private: }; GRenderWindow::GRenderWindow(QWidget* parent, EmuThread* emu_thread) - : QWidget(parent), child(nullptr), context(nullptr), emu_thread(emu_thread) { - + : QWidget(parent), emu_thread(emu_thread) { setWindowTitle(QStringLiteral("yuzu %1 | %2-%3") .arg(Common::g_build_name, Common::g_scm_branch, Common::g_scm_desc)); setAttribute(Qt::WA_AcceptTouchEvents); From 4abe8bb7ee9966f19e9fbff0dc62147681283025 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Tue, 16 Apr 2019 23:51:16 -0400 Subject: [PATCH 2/3] yuzu/bootmanager: Remove unnecessary includes This include isn't used anymore so it can be removed. --- src/yuzu/bootmanager.h | 1 - 1 file changed, 1 deletion(-) diff --git a/src/yuzu/bootmanager.h b/src/yuzu/bootmanager.h index 9608b959f4..3df33aca1c 100644 --- a/src/yuzu/bootmanager.h +++ b/src/yuzu/bootmanager.h @@ -10,7 +10,6 @@ #include #include #include -#include "common/thread.h" #include "core/core.h" #include "core/frontend/emu_window.h" From 69fdfc5296b7368e1a0d353a774e9e8c06725d96 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Wed, 17 Apr 2019 00:02:28 -0400 Subject: [PATCH 3/3] yuzu/bootmanager: Replace unnnecessary constructor initializer list member of GGLContext The default constructor will always run, even when not specified, so this is redundant. However, the context member can indeed be initialized in the constructor initializer list. --- src/yuzu/bootmanager.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/yuzu/bootmanager.cpp b/src/yuzu/bootmanager.cpp index a197831d8b..7eed9fcf3e 100644 --- a/src/yuzu/bootmanager.cpp +++ b/src/yuzu/bootmanager.cpp @@ -91,8 +91,8 @@ void EmuThread::run() { class GGLContext : public Core::Frontend::GraphicsContext { public: - explicit GGLContext(QOpenGLContext* shared_context) : surface() { - context = std::make_unique(shared_context); + explicit GGLContext(QOpenGLContext* shared_context) + : context{std::make_unique(shared_context)} { surface.setFormat(shared_context->format()); surface.create(); }