mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-09-23 09:48:41 +00:00
ControllerInterface: replace Reinitialize with RefreshDevices
The SDL backend crashes when you close a joystick after SDL_Quit has been called. Some backends don't need to be shutdown and re-initialized everytime, we can just ask to enumerate devices again.
This commit is contained in:
parent
cebb4d84f2
commit
3e69d066f5
21 changed files with 79 additions and 25 deletions
|
@ -10,7 +10,7 @@ namespace ciface
|
|||
{
|
||||
namespace Android
|
||||
{
|
||||
void Init()
|
||||
void PopulateDevices()
|
||||
{
|
||||
for (int i = 0; i < 8; ++i)
|
||||
g_controller_interface.AddDevice(std::make_shared<Touchscreen>(i));
|
||||
|
|
|
@ -11,7 +11,7 @@ namespace ciface
|
|||
{
|
||||
namespace Android
|
||||
{
|
||||
void Init();
|
||||
void PopulateDevices();
|
||||
class Touchscreen : public Core::Device
|
||||
{
|
||||
private:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue