diff options
author | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2021-07-15 20:22:53 +0300 |
---|---|---|
committer | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2021-07-15 20:22:53 +0300 |
commit | 48921a62322bd4eae17d1085256693aa66041dbd (patch) | |
tree | 1089cf9fec26fe99a2594121090fd7e43e039ffd /indra/newview/llviewerinput.cpp | |
parent | 0814ba33222fa86e73ca3e5351175ba4b7b545e8 (diff) |
SL-443 Keybindings: Backward compatibility
Diffstat (limited to 'indra/newview/llviewerinput.cpp')
-rw-r--r-- | indra/newview/llviewerinput.cpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/indra/newview/llviewerinput.cpp b/indra/newview/llviewerinput.cpp index f163e871c3..dff199d791 100644 --- a/indra/newview/llviewerinput.cpp +++ b/indra/newview/llviewerinput.cpp @@ -1212,7 +1212,8 @@ LLViewerInput::Keys::Keys() : first_person("first_person"), third_person("third_person"), sitting("sitting"), - edit_avatar("edit_avatar") + edit_avatar("edit_avatar"), + version("version", 0) {} void LLViewerInput::resetBindings() @@ -1240,6 +1241,16 @@ S32 LLViewerInput::loadBindingsXML(const std::string& filename) binding_count += loadBindingMode(keys.third_person, MODE_THIRD_PERSON); binding_count += loadBindingMode(keys.sitting, MODE_SITTING); binding_count += loadBindingMode(keys.edit_avatar, MODE_EDIT_AVATAR); + + // verify version + if (keys.version < 1) + { + // updating from a version that was not aware of LMouse bindings + for (S32 i = 0; i < MODE_COUNT; i++) + { + mLMouseDefaultHandling[i] = true; + } + } } return binding_count; } |