Showing the changes to interface/src/scripting/ControllerScriptingInterface.cpp (1 of 3 files). Show all
Unified · Split
| @@ -84,11 +84,11 @@ glm::vec2 ControllerScriptingInterface::getViewportDimensions() const { · 83 unmodified lines | ||
| 84 | 84 | return qApp->getUiSize(); |
| 85 | 85 | } |
| 86 | 86 | |
| 87 | −controller::InputController::Pointer ControllerScriptingInterface::createInputController(const QString& deviceName, const QString& tracker) { | |
| 88 | − // This is where we retreive the Device Tracker category and then the sub tracker within it | |
| 87 | +controller::InputController* ControllerScriptingInterface::createInputController(const QString& deviceName, const QString& tracker) { | |
| 88 | + // This is where we retrieve the Device Tracker category and then the sub tracker within it | |
| 89 | 89 | auto icIt = _inputControllers.find(0); |
| 90 | 90 | if (icIt != _inputControllers.end()) { |
| 91 | − return (*icIt).second; | |
| 91 | + return (*icIt).second.get(); | |
| 92 | 92 | } |
| 93 | 93 | |
| 94 | 94 | |
| @@ -110,15 +110,15 @@ controller::InputController::Pointer ControllerScriptingInterface::createInputCo · 15 unmodified lines | ||
| 110 | 110 | controller::InputController::Pointer inputController = std::make_shared<InputController>(deviceID, trackerID, this); |
| 111 | 111 | controller::InputController::Key key = inputController->getKey(); |
| 112 | 112 | _inputControllers.insert(InputControllerMap::value_type(key, inputController)); |
| 113 | − return inputController; | |
| 113 | + return inputController.get(); | |
| 114 | 114 | } |
| 115 | 115 | } |
| 116 | 116 | } |
| 117 | 117 | |
| 118 | − return controller::InputController::Pointer(); | |
| 118 | + return nullptr; | |
| 119 | 119 | } |
| 120 | 120 | |
| 121 | −void ControllerScriptingInterface::releaseInputController(controller::InputController::Pointer input) { | |
| 121 | +void ControllerScriptingInterface::releaseInputController(controller::InputController* input) { | |
| 122 | 122 | _inputControllers.erase(input->getKey()); |
| 123 | 123 | } |
| 124 | 124 | |