! * \brief IPProcessGrid::keyPressEvent * \param event */
| 544 | * \param event |
| 545 | */ |
| 546 | void IPProcessGrid::keyPressEvent(QKeyEvent *event) |
| 547 | { |
| 548 | Qt::KeyboardModifiers modifiers = event->modifiers(); |
| 549 | |
| 550 | if(event->key() == Qt::Key_Space) |
| 551 | { |
| 552 | setDragMode(QGraphicsView::ScrollHandDrag); |
| 553 | } |
| 554 | |
| 555 | if(event->key() == Qt::Key_F && modifiers&Qt::ControlModifier) |
| 556 | { |
| 557 | _mainWindow->hideProcessSettings(); |
| 558 | _mainWindow->setFilterFocus(); |
| 559 | } |
| 560 | |
| 561 | if(event->key() == Qt::Key_Delete || event->key() == Qt::Key_Backspace) |
| 562 | { |
| 563 | _scene->deleteSelectedItems(); |
| 564 | } |
| 565 | |
| 566 | if(event->key() == Qt::Key_Escape) |
| 567 | { |
| 568 | _mainWindow->hideProcessSettings(); |
| 569 | } |
| 570 | } |
| 571 | |
| 572 | /*! |
| 573 | * \brief IPProcessGrid::keyReleaseEvent |
nothing calls this directly
no test coverage detected