forked from qt-creator/qt-creator
eat tooltip events when control is pressed, otherwise the tools
destroy the navigation experience
This commit is contained in:
@@ -1480,6 +1480,8 @@ bool BaseTextEditor::viewportEvent(QEvent *event)
|
||||
setTextCursor(cursorForPosition(ce->pos()));
|
||||
} else if (event->type() == QEvent::ToolTip) {
|
||||
const QHelpEvent *he = static_cast<QHelpEvent*>(event);
|
||||
if (QApplication::keyboardModifiers() & Qt::ControlModifier)
|
||||
return true; // eat tooltip event when control is pressed
|
||||
const QPoint &pos = he->pos();
|
||||
|
||||
// Allow plugins to show tooltips
|
||||
|
||||
Reference in New Issue
Block a user