diff options
| author | JosJuice <josjuice@gmail.com> | 2022-06-25 17:31:31 +0200 |
|---|---|---|
| committer | JosJuice <josjuice@gmail.com> | 2022-07-17 14:03:04 +0200 |
| commit | dabad822193f23bd01c13c4d0798f0a507e910eb (patch) | |
| tree | e1952b7e93625fa3450b2fca075159c49a43487b /Source/Android/jni/MainAndroid.cpp | |
| parent | 2f3c0cdbc594cdcb76644e1e77aa185a1e50a244 (diff) | |
Require frontend to initialize controllers
We currently have two different code paths for initializing controllers:
Either the frontend (DolphinQt) can do it, or if the frontend doesn't do
it, the core will do it automatically when booting. Having these two
paths has caused problems in the past due to only one frontend being
tested (see de7ef47548). I would like to get rid of the latter path to
avoid further problems like this.
Diffstat (limited to 'Source/Android/jni/MainAndroid.cpp')
| -rw-r--r-- | Source/Android/jni/MainAndroid.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/Source/Android/jni/MainAndroid.cpp b/Source/Android/jni/MainAndroid.cpp index 77c373a481..d41ebe4cc9 100644 --- a/Source/Android/jni/MainAndroid.cpp +++ b/Source/Android/jni/MainAndroid.cpp @@ -2,7 +2,6 @@ // SPDX-License-Identifier: GPL-2.0-or-later #include <EGL/egl.h> -#include <UICommon/GameFile.h> #include <android/log.h> #include <android/native_window_jni.h> #include <cstdio> @@ -56,13 +55,13 @@ #include "InputCommon/ControllerInterface/Touch/ButtonManager.h" #include "InputCommon/GCAdapter.h" +#include "UICommon/GameFile.h" #include "UICommon/UICommon.h" #include "VideoCommon/OnScreenDisplay.h" #include "VideoCommon/RenderBase.h" #include "VideoCommon/VideoBackendBase.h" -#include "../../Core/Common/WindowSystemInfo.h" #include "jni/AndroidCommon/AndroidCommon.h" #include "jni/AndroidCommon/IDCache.h" @@ -521,7 +520,7 @@ JNIEXPORT void JNICALL Java_org_dolphinemu_dolphinemu_NativeLibrary_Initialize(J Common::AndroidSetReportHandler(&ReportSend); DolphinAnalytics::AndroidSetGetValFunc(&GetAnalyticValue); UICommon::Init(); - GCAdapter::Init(); + UICommon::InitControllers(WindowSystemInfo(WindowSystemType::Android, nullptr, nullptr, nullptr)); } JNIEXPORT void JNICALL Java_org_dolphinemu_dolphinemu_NativeLibrary_ReportStartToAnalytics(JNIEnv*, |
