diff options
author | Sascha Hlusiak <saschahlusiak@arcor.de> | 2007-08-11 22:32:54 +0200 |
---|---|---|
committer | Sascha Hlusiak <saschahlusiak@arcor.de> | 2007-08-11 22:32:54 +0200 |
commit | 38297b06226f115ca4a25557bcb7f8c936424abc (patch) | |
tree | 746966f897c8e299d9bca9430af68264f69150d5 /src | |
parent | dd396931b76c682f03323566f28b248afb1cb79d (diff) |
Fixed button mapping to an axis needing amplify value.
Button mapping without amplify value like "axis=x" used uninitialized value for amplify,
making an amplify value mandatory. With no amplify value, 1.0 is assumed.
Diffstat (limited to 'src')
-rw-r--r-- | src/jstk_options.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/jstk_options.c b/src/jstk_options.c index 8991813..9180c8e 100644 --- a/src/jstk_options.c +++ b/src/jstk_options.c @@ -128,6 +128,7 @@ jstkParseButtonOption(const char* org, button->buttonnumber = jstkGetButtonNumberInMap(priv, value); } else if (sscanf(param, "axis=%15s", p) == 1) { p[15]='\0'; + fvalue = 1.0f; button->mapping = jstkGetAxisMapping(&fvalue, p, name); button->amplify = fvalue; button->currentspeed = 1.0f; |