summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--share/CMakeLists.txt2
-rw-r--r--src/plugins/help/helpwidget.cpp5
-rw-r--r--src/plugins/help/openpagesswitcher.cpp4
-rw-r--r--tests/system/shared/qtcreator.py10
4 files changed, 14 insertions, 7 deletions
diff --git a/share/CMakeLists.txt b/share/CMakeLists.txt
index eb3c779b40..b1e61d596e 100644
--- a/share/CMakeLists.txt
+++ b/share/CMakeLists.txt
@@ -6,6 +6,6 @@ if (NOT APPLE AND NOT WIN32)
applications
metainfo
DESTINATION
- share
+ ${CMAKE_INSTALL_DATAROOTDIR}
)
endif()
diff --git a/src/plugins/help/helpwidget.cpp b/src/plugins/help/helpwidget.cpp
index a72ff4c6b4..1f235dcce6 100644
--- a/src/plugins/help/helpwidget.cpp
+++ b/src/plugins/help/helpwidget.cpp
@@ -931,7 +931,10 @@ void HelpWidget::updateCloseButton()
{
if (supportsPages()) {
const bool closeOnReturn = LocalHelpManager::returnOnClose() && m_style == ModeWidget;
- m_closeAction->setEnabled(closeOnReturn || m_viewerStack->count() > 1);
+ const bool hasMultiplePages = m_viewerStack->count() > 1;
+ m_closeAction->setEnabled(closeOnReturn || hasMultiplePages);
+ m_gotoPrevious->setEnabled(hasMultiplePages);
+ m_gotoNext->setEnabled(hasMultiplePages);
}
}
diff --git a/src/plugins/help/openpagesswitcher.cpp b/src/plugins/help/openpagesswitcher.cpp
index 20117828a7..5991efd0dd 100644
--- a/src/plugins/help/openpagesswitcher.cpp
+++ b/src/plugins/help/openpagesswitcher.cpp
@@ -81,7 +81,9 @@ void OpenPagesSwitcher::gotoPreviousPage()
void OpenPagesSwitcher::selectAndHide()
{
setVisible(false);
- emit setCurrentPage(m_openPagesWidget->currentIndex());
+ QModelIndex index = m_openPagesWidget->currentIndex();
+ if (index.isValid())
+ emit setCurrentPage(index);
}
void OpenPagesSwitcher::selectCurrentPage(int index)
diff --git a/tests/system/shared/qtcreator.py b/tests/system/shared/qtcreator.py
index 76dbd7071d..9ecec40a20 100644
--- a/tests/system/shared/qtcreator.py
+++ b/tests/system/shared/qtcreator.py
@@ -66,10 +66,12 @@ def startQC(additionalParameters=None, withPreparedSettingsPath=True, closeLinkT
appWithOptions.extend(('-platform', 'windows:dialogs=none'))
test.log("Starting now: %s" % ' '.join(appWithOptions))
appContext = startApplication(' '.join(appWithOptions))
- if closeLinkToQt:
- clickButton(waitForObject(":*Qt Creator.Do Not Show Again_QToolButton"))
- if cancelTour:
- clickButton(waitForObject(":*Qt Creator.Do Not Show Again_QToolButton"))
+ if closeLinkToQt or cancelTour:
+ progressBarWait(3000) # wait for the "Updating documentation" progress bar
+ if closeLinkToQt:
+ clickButton(waitForObject(":*Qt Creator.Do Not Show Again_QToolButton"))
+ if cancelTour:
+ clickButton(waitForObject(":*Qt Creator.Do Not Show Again_QToolButton"))
return appContext;
def startedWithoutPluginError():