projects
/
oweals
/
minetest.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5433e9b
)
Fix always using the xbox layout (reported by coverity).
author
Ekdohibs
<nathanael.courant@laposte.net>
Tue, 18 Apr 2017 04:40:53 +0000
(06:40 +0200)
committer
Ekdohibs
<nathanael.courant@laposte.net>
Tue, 18 Apr 2017 04:47:08 +0000
(06:47 +0200)
src/client/joystick_controller.cpp
patch
|
blob
|
history
diff --git
a/src/client/joystick_controller.cpp
b/src/client/joystick_controller.cpp
index e6a572adbee17313343427fa55407fcd3f0a77f7..3e1442793f680f0d98d532e416e402b7f7925ebd 100644
(file)
--- a/
src/client/joystick_controller.cpp
+++ b/
src/client/joystick_controller.cpp
@@
-186,7
+186,7
@@
void JoystickController::onJoystickConnect(const std::vector<irr::SJoystickInfo>
}
void JoystickController::setLayoutFromControllerName(std::string name) {
- if (lowercase(name).find("xbox")
>= 0
) {
+ if (lowercase(name).find("xbox")
!= std::string::npos
) {
m_layout = create_xbox_layout();
} else {
m_layout = create_default_layout();