ControllerInterface/Android: Implement device population

This commit is contained in:
JosJuice
2023-03-03 22:28:23 +01:00
parent 68ebb5c33e
commit 792cb62195
4 changed files with 612 additions and 4 deletions
+3
View File
@@ -146,6 +146,9 @@ elseif(ANDROID)
ControllerInterface/Touch/InputOverrider.cpp
ControllerInterface/Touch/InputOverrider.h
)
target_link_libraries(inputcommon PRIVATE
androidcommon
)
endif()
if(NOT ANDROID)
File diff suppressed because it is too large Load Diff
@@ -1,9 +1,13 @@
// Copyright 2008 Dolphin Emulator Project
// Copyright 2021 Dolphin Emulator Project
// SPDX-License-Identifier: GPL-2.0-or-later
#pragma once
namespace ciface::Android
{
void Init();
void Shutdown();
void PopulateDevices();
} // namespace ciface::Android
@@ -67,7 +67,7 @@ void ControllerInterface::Initialize(const WindowSystemInfo& wsi)
m_input_backends.emplace_back(ciface::SDL::CreateInputBackend(this));
#endif
#ifdef CIFACE_USE_ANDROID
// nothing needed
ciface::Android::Init();
#endif
#ifdef CIFACE_USE_EVDEV
m_input_backends.emplace_back(ciface::evdev::CreateInputBackend(this));
@@ -237,7 +237,7 @@ void ControllerInterface::Shutdown()
ciface::Quartz::DeInit();
#endif
#ifdef CIFACE_USE_ANDROID
// nothing needed
ciface::Android::Shutdown();
#endif
// Empty the container of input backends to deconstruct and deinitialize them.