Add "Advanced..." button to find tool bar that opens the search dialog.

We had multiple cases where people were assuming that you can't do
project wide search/replace, because they tried Ctrl+f and that is only
single file.

Reviewed-by: Thorbjørn Lindeijer
This commit is contained in:
con
2010-07-14 15:18:56 +02:00
parent 5652337785
commit 9eba87bd92
4 changed files with 16 additions and 1 deletions

View File

@@ -140,6 +140,8 @@ FindToolBar::FindToolBar(FindPlugin *plugin, CurrentDocumentFind *currentDocumen
Core::ActionContainer *mfind = am->actionContainer(Constants::M_FIND);
Core::Command *cmd;
m_ui.advancedButton->setDefaultAction(am->command(Constants::ADVANCED_FIND)->action());
QIcon icon = QIcon::fromTheme(QLatin1String("edit-find-replace"));
m_findInDocumentAction = new QAction(icon, tr("Find/Replace"), this);
cmd = am->registerAction(m_findInDocumentAction, Constants::FIND_IN_DOCUMENT, globalcontext);
@@ -345,6 +347,7 @@ void FindToolBar::updateToolBar()
m_ui.replaceButton->setVisible(replaceEnabled);
m_ui.replaceNextButton->setVisible(replaceEnabled);
m_ui.replaceAllButton->setVisible(replaceEnabled);
m_ui.advancedButton->setVisible(replaceEnabled);
layout()->invalidate();
if (!replaceEnabled && enabled && replaceFocus)