Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Valentin Platzgummer
qgroundcontrol
Commits
c4d33478
Commit
c4d33478
authored
Jan 18, 2017
by
Nate Weibley
Browse files
SDL: warn with SDL error string when joystick feature detection fails
parent
4bb4412f
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/Joystick/JoystickSDL.cc
View file @
c4d33478
...
...
@@ -41,9 +41,13 @@ QMap<QString, Joystick*> JoystickSDL::discover(MultiVehicleManager* _multiVehicl
hatCount
=
0
;
}
else
{
isGameController
=
false
;
SDL_ClearError
();
axisCount
=
SDL_JoystickNumAxes
(
sdlJoystick
);
buttonCount
=
SDL_JoystickNumButtons
(
sdlJoystick
);
hatCount
=
SDL_JoystickNumHats
(
sdlJoystick
);
if
(
axisCount
<
0
||
buttonCount
<
0
||
hatCount
<
0
)
{
qCWarning
(
JoystickLog
)
<<
"
\t
libsdl error parsing joystick features:"
<<
SDL_GetError
();
}
}
SDL_JoystickClose
(
sdlJoystick
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment