History

Correcting update order to fix mouse

Brad Davis committed 11 years ago

Commit a8e707c1 parent 184303d2 files · +8 −21Browse files

Showing the changes to interface/src/scripting/ControllerScriptingInterface.cpp (1 of 2 files). Show all

Unified · Split

interface/src/scripting/ControllerScriptingInterface.cpp+8−5
@@ -173,15 +173,18 @@ void ControllerScriptingInterface::update() { · 172 unmodified lines
173173 float delta = now - last;
174174 last = now;
175175
176− for(auto inputPlugin : PluginManager::getInstance()->getInputPlugins()) {
176+ DependencyManager::get<UserInputMapper>()->update(delta);
177+
178+ bool jointsCaptured = false;
179+ for (auto inputPlugin : PluginManager::getInstance()->getInputPlugins()) {
177180 if (inputPlugin->isActive()) {
178− inputPlugin->pluginUpdate(delta, false);
181+ inputPlugin->pluginUpdate(delta, jointsCaptured);
182+ if (inputPlugin->isJointController()) {
183+ jointsCaptured = true;
184+ }
179185 }
180186 }
181187
182− auto userInputMapper = DependencyManager::get<UserInputMapper>();
183− userInputMapper->update(delta);
184−
185188 for (auto entry : _inputControllers) {
186189 entry.second->update();
187190 }