| 505 | } |
| 506 | |
| 507 | void QmitkSliderLevelWindowWidget::contextMenuEvent(QContextMenuEvent *) |
| 508 | { |
| 509 | m_Contextmenu->SetLevelWindowManager(m_Manager.GetPointer()); |
| 510 | auto contextMenu = new QMenu(this); |
| 511 | Q_CHECK_PTR(contextMenu); |
| 512 | if (m_ScaleVisible) |
| 513 | contextMenu->addAction(tr("Hide Scale"), this, SLOT(HideScale())); |
| 514 | else |
| 515 | contextMenu->addAction(tr("Show Scale"), this, SLOT(ShowScale())); |
| 516 | contextMenu->addSeparator(); |
| 517 | m_Contextmenu->GetContextMenu(contextMenu); |
| 518 | |
| 519 | // Fix: Bug #13327 we need to reset the m_MouseDown value |
| 520 | // otherwise the cursor is not correctly restored afterwards |
| 521 | m_MouseDown = false; |
| 522 | } |
| 523 | |
| 524 | void QmitkSliderLevelWindowWidget::HideScale() |
| 525 | { |
nothing calls this directly
no test coverage detected