Showing the changes to interface/src/scripting/ControllerScriptingInterface.cpp (1 of 2 files). Show all
Unified · Split
| @@ -173,15 +173,18 @@ void ControllerScriptingInterface::update() { · 172 unmodified lines | ||
| 173 | 173 | float delta = now - last; |
| 174 | 174 | last = now; |
| 175 | 175 | |
| 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()) { | |
| 177 | 180 | if (inputPlugin->isActive()) { |
| 178 | − inputPlugin->pluginUpdate(delta, false); | |
| 181 | + inputPlugin->pluginUpdate(delta, jointsCaptured); | |
| 182 | + if (inputPlugin->isJointController()) { | |
| 183 | + jointsCaptured = true; | |
| 184 | + } | |
| 179 | 185 | } |
| 180 | 186 | } |
| 181 | 187 | |
| 182 | − auto userInputMapper = DependencyManager::get<UserInputMapper>(); | |
| 183 | − userInputMapper->update(delta); | |
| 184 | − | |
| 185 | 188 | for (auto entry : _inputControllers) { |
| 186 | 189 | entry.second->update(); |
| 187 | 190 | } |