summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorck <qt-info@nokia.com>2009-12-08 14:49:48 (GMT)
committerck <qt-info@nokia.com>2009-12-08 14:49:48 (GMT)
commitc4cd151801d4322c694609b5d12a5dd3f59422e9 (patch)
treec25cc8edd68ffbb6b28858d495531f72ac9270bc /tools
parentd3dbb40fa67cf566288dce71834213dbe8e119e9 (diff)
downloadQt-c4cd151801d4322c694609b5d12a5dd3f59422e9.zip
Qt-c4cd151801d4322c694609b5d12a5dd3f59422e9.tar.gz
Qt-c4cd151801d4322c694609b5d12a5dd3f59422e9.tar.bz2
Assistant: Allow search tab to be displayed on start-up.
Reviewed-by: kh1
Diffstat (limited to 'tools')
-rw-r--r--tools/assistant/tools/assistant/centralwidget.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/assistant/tools/assistant/centralwidget.cpp b/tools/assistant/tools/assistant/centralwidget.cpp
index 10495ad..d148095 100644
--- a/tools/assistant/tools/assistant/centralwidget.cpp
+++ b/tools/assistant/tools/assistant/centralwidget.cpp
@@ -314,7 +314,7 @@ CentralWidget::~CentralWidget()
}
HelpEngineWrapper &helpEngine = HelpEngineWrapper::instance();
- helpEngine.setLastTabPage(lastTabPage);
+ helpEngine.setLastTabPage(tabWidget->currentIndex());
helpEngine.setLastShownPages(currentPages);
helpEngine.setSearchWasAttached(searchAttached);
helpEngine.setLastZoomFactors(zoomFactors);
@@ -473,7 +473,7 @@ void CentralWidget::setLastShownPages()
const bool searchIsAttached = m_searchWidget->isAttached();
const bool searchWasAttached = helpEngine.searchWasAttached();
int tabToShow = helpEngine.lastTabPage();
- if (searchWasAttached && !searchIsAttached)
+ if (searchWasAttached && !searchIsAttached && tabToShow != 0)
--tabToShow;
else if (!searchWasAttached && searchIsAttached)
++tabToShow;