welcome screen: populate example combobox

When an example is selected, help and the project are opened
in a split view. We try to read the xml file provided for
QtDemo to extract details about the examples provided. Will
try all available Qts, starting with the default version. Will
fail gracefully (provide a message and disable controls) if
examples or demos cannot be found. Will work if help is not
found, but show an error.
This commit is contained in:
Daniel Molkentin
2009-05-28 18:15:02 +02:00
parent 82153bf5fd
commit 99fb291695
7 changed files with 217 additions and 8 deletions

View File

@@ -526,6 +526,7 @@ void HelpPlugin::extensionsInitialized()
if (Core::Internal::WelcomeMode *welcomeMode = qobject_cast<Core::Internal::WelcomeMode*>(m_core->modeManager()->mode(Core::Constants::MODE_WELCOME))) {
connect(welcomeMode, SIGNAL(openHelpPage(const QString&)), this, SLOT(openHelpPage(const QString&)));
connect(welcomeMode, SIGNAL(openContextHelpPage(const QString&)), this, SLOT(openContextHelpPage(QString)));
}
}
@@ -557,6 +558,12 @@ void HelpPlugin::modeChanged(Core::IMode *mode)
}
}
void HelpPlugin::openContextHelpPage(const QString &url)
{
Core::RightPaneWidget::instance()->setShown(true);
m_helpViewerForSideBar->setSource(QUrl(url));
}
void HelpPlugin::activateContext()
{
using namespace Core;