Showing the changes to interface/src/Application.cpp (1 of 3 files). Show all
Unified · Split
| @@ -2161,17 +2161,16 @@ void Application::mouseMoveEvent(QMouseEvent* event) { · 2160 unmodified lines | |||
| 2161 | 2161 | ||
| 2162 | maybeToggleMenuVisible(event); | 2162 | maybeToggleMenuVisible(event); |
| 2163 | 2163 | ||
| 2164 | auto& compositor = getApplicationCompositor(); | ||
| 2164 | // if this is a real mouse event, and we're in HMD mode, then we should use it to move the | 2165 | // if this is a real mouse event, and we're in HMD mode, then we should use it to move the |
| 2165 | // compositor reticle | 2166 | // compositor reticle |
| 2166 | if (event->spontaneous()) { | 2167 | // handleRealMouseMoveEvent() will return true, if we shouldn't process the event further |
| 2167 | // handleRealMouseMoveEvent() will return true, if we shouldn't process the event further | 2168 | if (!compositor.fakeEventActive() && compositor.handleRealMouseMoveEvent()) { |
| 2168 | if (getApplicationCompositor().handleRealMouseMoveEvent()) { | 2169 | return; // bail |
| 2169 | return; // bail | ||
| 2170 | } | ||
| 2171 | } | 2170 | } |
| 2172 | 2171 | ||
| 2173 | auto offscreenUi = DependencyManager::get<OffscreenUi>(); | 2172 | auto offscreenUi = DependencyManager::get<OffscreenUi>(); |
| 2174 | auto eventPosition = getApplicationCompositor().getMouseEventPosition(event); | 2173 | auto eventPosition = compositor.getMouseEventPosition(event); |
| 2175 | QPointF transformedPos = offscreenUi->mapToVirtualScreen(eventPosition, _glWidget); | 2174 | QPointF transformedPos = offscreenUi->mapToVirtualScreen(eventPosition, _glWidget); |
| 2176 | auto button = event->button(); | 2175 | auto button = event->button(); |
| 2177 | auto buttons = event->buttons(); | 2176 | auto buttons = event->buttons(); |