forked from qt-creator/qt-creator
Escape key: Fix more cases of closing find tool bar
1. Close find, but not output panes, if pressing ESC while focus is in the editor that has the find tool bar 2. If find tool bar is visible anywhere else (e.g. in the navigation panes), close it together with the output panes (it was not hidden at all in that case). Change-Id: Ia91900144c9f31ec53d1a046aa2972ac22b1a6b6 Reviewed-by: Daniel Teske <daniel.teske@digia.com>
This commit is contained in:
@@ -679,8 +679,7 @@ void EditorManagerPrivate::doEscapeKeyFocusMoveMagic()
|
|||||||
if (findPane && findPane->isVisible() && findPane->isUsedByWidget(focus)) {
|
if (findPane && findPane->isVisible() && findPane->isUsedByWidget(focus)) {
|
||||||
findPane->hide();
|
findPane->hide();
|
||||||
stuffHidden = true;
|
stuffHidden = true;
|
||||||
}
|
} else if (!( editorViewVisible && !editorViewActive && editorView->window() == activeWindow )) {
|
||||||
if (!( editorViewVisible && !editorViewActive && editorView->window() == activeWindow )) {
|
|
||||||
QWidget *outputPane = OutputPanePlaceHolder::getCurrent();
|
QWidget *outputPane = OutputPanePlaceHolder::getCurrent();
|
||||||
if (outputPane && outputPane->isVisible() && outputPane->window() == activeWindow) {
|
if (outputPane && outputPane->isVisible() && outputPane->window() == activeWindow) {
|
||||||
OutputPaneManager::instance()->slotHide();
|
OutputPaneManager::instance()->slotHide();
|
||||||
@@ -691,6 +690,10 @@ void EditorManagerPrivate::doEscapeKeyFocusMoveMagic()
|
|||||||
RightPaneWidget::instance()->setShown(false);
|
RightPaneWidget::instance()->setShown(false);
|
||||||
stuffHidden = true;
|
stuffHidden = true;
|
||||||
}
|
}
|
||||||
|
if (findPane && findPane->isVisible() && findPane->window() == activeWindow) {
|
||||||
|
findPane->hide();
|
||||||
|
stuffHidden = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (stuffHidden)
|
if (stuffHidden)
|
||||||
return;
|
return;
|
||||||
|
Reference in New Issue
Block a user