OSDN Git Service

Add Help Menu Entry that points to the bug tracker.
authorDaniel Molkentin <daniel.molkentin@nokia.com>
Tue, 26 Jul 2011 16:38:27 +0000 (18:38 +0200)
committerDaniel Molkentin <daniel.molkentin@nokia.com>
Thu, 28 Jul 2011 13:39:06 +0000 (15:39 +0200)
Task-Number: QTCREATORBUG-5098
Change-Id: Ibed9e8eea98cb716f2eff29582a39e133c7d8607
Reviewed-on: http://codereview.qt.nokia.com/2221
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
src/plugins/help/helpplugin.cpp
src/plugins/help/helpplugin.h

index 5ae3576..baca498 100644 (file)
@@ -261,6 +261,11 @@ bool HelpPlugin::initialize(const QStringList &arguments, QString *error)
     am->actionContainer(M_HELP)->addAction(cmd, Core::Constants::G_HELP_HELP);
     connect(action, SIGNAL(triggered()), this, SLOT(slotOpenSupportPage()));
 
+    action = new QAction(tr("Report Bug"), this);
+    cmd = am->registerAction(action, Core::Id("Help.ReportBug"), globalcontext);
+    am->actionContainer(M_HELP)->addAction(cmd, Core::Constants::G_HELP_HELP);
+    connect(action, SIGNAL(triggered()), this, SLOT(slotReportBug()));
+
 #ifndef Q_WS_MAC
     action = new QAction(this);
     action->setSeparator(true);
@@ -1210,6 +1215,11 @@ void HelpPlugin::slotOpenSupportPage()
     switchToHelpMode(QUrl("qthelp://com.nokia.qtcreator/doc/technical-support.html"));
 }
 
+void HelpPlugin::slotReportBug()
+{
+    QDesktopServices::openUrl(QUrl("http://bugreports.qt.nokia.com"));
+}
+
 void HelpPlugin::openFindToolBar()
 {
     if (Find::FindPlugin::instance())
index 2700cd6..97443d5 100644 (file)
@@ -116,6 +116,7 @@ private slots:
     void slotAboutToShowNextMenu();
     void slotOpenActionUrl(QAction *action);
     void slotOpenSupportPage();
+    void slotReportBug();
 
     void openFindToolBar();