Merge pull request #427 from sgadrat/qt-input-load
fix loading of keyboard mapping for controllers > 1
This commit is contained in:
commit
b9e53bbe95
|
@ -31,6 +31,7 @@
|
|||
//#include <unistd.h>
|
||||
//#include <fcntl.h>
|
||||
#include <cerrno>
|
||||
#include <cstring>
|
||||
|
||||
//#define MAX_JOYSTICKS 32
|
||||
|
||||
|
@ -414,7 +415,7 @@ int GamePad_t::init(int port, const char *guid, const char *profile)
|
|||
|
||||
// If we get to this point and still have not found a
|
||||
// game controller, then load default keyboard.
|
||||
if ((portNum == 0) && (devIdx < 0))
|
||||
if ((portNum == 0 || strnlen(profile, 1) > 0) && (devIdx < 0))
|
||||
{
|
||||
if (loadProfile(profile))
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue