summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorkh <qtc-committer@nokia.com>2009-04-23 13:08:23 (GMT)
committerkh <qtc-committer@nokia.com>2009-04-23 13:08:23 (GMT)
commita9157844903870521d94a5a576efd143f04f2aa3 (patch)
tree20b271a19db9dd804662fcae7d03262ed800fb14 /tools
parentb51dd5a7b328291c5dbda540ce228e7d867662cb (diff)
downloadQt-a9157844903870521d94a5a576efd143f04f2aa3.zip
Qt-a9157844903870521d94a5a576efd143f04f2aa3.tar.gz
Qt-a9157844903870521d94a5a576efd143f04f2aa3.tar.bz2
update the filter combobox if we set a passed filter
Diffstat (limited to 'tools')
-rw-r--r--tools/assistant/tools/assistant/mainwindow.cpp13
1 files changed, 11 insertions, 2 deletions
diff --git a/tools/assistant/tools/assistant/mainwindow.cpp b/tools/assistant/tools/assistant/mainwindow.cpp
index cd6cdf1..c1e9027 100644
--- a/tools/assistant/tools/assistant/mainwindow.cpp
+++ b/tools/assistant/tools/assistant/mainwindow.cpp
@@ -228,8 +228,17 @@ MainWindow::MainWindow(CmdLineParser *cmdLine, QWidget *parent)
else if (m_cmdLine->bookmarks() == CmdLineParser::Activate)
showBookmarks();
- if (!m_cmdLine->currentFilter().isEmpty())
- m_helpEngine->setCurrentFilter(m_cmdLine->currentFilter());
+ if (!m_cmdLine->currentFilter().isEmpty()) {
+ const QString &curFilter = m_cmdLine->currentFilter();
+ m_helpEngine->setCurrentFilter(curFilter);
+ int idx = m_filterCombo->findText(curFilter);
+ if (idx >= 0) {
+ bool blocked = m_filterCombo->signalsBlocked();
+ m_filterCombo->blockSignals(true);
+ m_filterCombo->setCurrentIndex(idx);
+ m_filterCombo->blockSignals(blocked);
+ }
+ }
if (usesDefaultCollection())
QTimer::singleShot(0, this, SLOT(lookForNewQtDocumentation()));