diff options
author | Paul Lemire <paul.lemire@kdab.com> | 2015-12-01 16:22:35 +0100 |
---|---|---|
committer | Sean Harmer <sean.harmer@kdab.com> | 2015-12-04 19:07:21 +0000 |
commit | 670d242385172262f802f378c996545cd328ca94 (patch) | |
tree | d0a06fcd98ad5763d5b7165f381648e02e2a28d8 /src/input/frontend | |
parent | 209e2eecd33d8194fe2e4f9501e4f8eb9ee836da (diff) |
Store vector of active AxisActionHandlers
Change-Id: I33fb52391936d8f19757351aded8b1dae662fee3
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Diffstat (limited to 'src/input/frontend')
-rw-r--r-- | src/input/frontend/qinputaspect.cpp | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/input/frontend/qinputaspect.cpp b/src/input/frontend/qinputaspect.cpp index ad1a01e0c..fc08b2959 100644 --- a/src/input/frontend/qinputaspect.cpp +++ b/src/input/frontend/qinputaspect.cpp @@ -109,7 +109,7 @@ QInputAspect::QInputAspect(QObject *parent) registerBackendType<QAxisSetting>(QBackendNodeFunctorPtr(new Input::InputNodeFunctor<Input::AxisSetting, Input::AxisSettingManager>(d_func()->m_inputHandler->axisSettingManager()))); registerBackendType<Qt3DInput::QAction>(QBackendNodeFunctorPtr(new Input::InputNodeFunctor<Input::Action, Input::ActionManager>(d_func()->m_inputHandler->actionManager()))); registerBackendType<QActionInput>(QBackendNodeFunctorPtr(new Input::InputNodeFunctor<Input::ActionInput, Input::ActionInputManager>(d_func()->m_inputHandler->actionInputManager()))); - registerBackendType<Qt3DInput::QAxisActionHandler>(QBackendNodeFunctorPtr(new Input::InputNodeFunctor<Input::AxisActionHandler, Input::AxisActionHandlerManager>(d_func()->m_inputHandler->axisActionHandlerManager()))); + registerBackendType<Qt3DInput::QAxisActionHandler>(QBackendNodeFunctorPtr(new Input::AxisActionHandlerNodeFunctor(d_func()->m_inputHandler->axisActionHandlerManager()))); registerBackendType<QLogicalDevice>(QBackendNodeFunctorPtr(new Input::LogicalDeviceNodeFunctor(d_func()->m_inputHandler->logicalDeviceManager()))); loadInputDevicePlugins(); @@ -179,9 +179,14 @@ QVector<QAspectJobPtr> QInputAspect::jobsToExecute(qint64 time) jobs += axisActionJobs; - // TO DO: - // Have Jobs that update the LogicalDevice - // Have Jobs that update the AxisHandlers/ActionHandlers + // For each AxisActionInputHandler + // Find the LogicalDevice + // Find each Axis + // Check if their values have changed since the last time + // If so -> add to notification payload + // Find each Action + // Check if action state has changed since last frame + // If so -> add to notification payload return jobs; } |