| 429 | } |
| 430 | |
| 431 | void DrawWidget::keyPressEvent(QKeyEvent * e) |
| 432 | { |
| 433 | if (m_screenshotMode) |
| 434 | return; |
| 435 | |
| 436 | if (IsLeftButton(QGuiApplication::mouseButtons()) && e->key() == Qt::Key_Control) |
| 437 | { |
| 438 | df::TouchEvent event; |
| 439 | event.SetTouchType(df::TouchEvent::TOUCH_DOWN); |
| 440 | df::Touch touch; |
| 441 | touch.m_id = 0; |
| 442 | touch.m_location = m2::PointD(L2D(QCursor::pos().x()), L2D(QCursor::pos().y())); |
| 443 | event.SetFirstTouch(touch); |
| 444 | event.SetSecondTouch(GetSymmetrical(touch)); |
| 445 | |
| 446 | m_framework.TouchEvent(event); |
| 447 | } |
| 448 | } |
| 449 | |
| 450 | void DrawWidget::keyReleaseEvent(QKeyEvent * e) |
| 451 | { |
nothing calls this directly
no test coverage detected