Added a link to online documentation in the Qt GUI help menu.
This commit is contained in:
parent
7e3086d92c
commit
14b07ab5f2
|
@ -35,6 +35,8 @@
|
|||
#include <QFileDialog>
|
||||
#include <QMessageBox>
|
||||
#include <QInputDialog>
|
||||
#include <QDesktopServices>
|
||||
#include <QUrl>
|
||||
|
||||
#include "../../fceu.h"
|
||||
#include "../../fds.h"
|
||||
|
@ -924,6 +926,14 @@ void consoleWin_t::createMainMenu(void)
|
|||
connect(msgLogAct, SIGNAL(triggered()), this, SLOT(openMsgLogWin(void)) );
|
||||
|
||||
helpMenu->addAction(msgLogAct);
|
||||
|
||||
// Help -> Documentation
|
||||
act = new QAction(tr("&Docs (Online)"), this);
|
||||
act->setStatusTip(tr("Documentation"));
|
||||
act->setIcon( style->standardIcon( QStyle::SP_DialogHelpButton ) );
|
||||
connect(act, SIGNAL(triggered()), this, SLOT(openOnlineDocs(void)) );
|
||||
|
||||
helpMenu->addAction(act);
|
||||
};
|
||||
//---------------------------------------------------------------------------
|
||||
void consoleWin_t::toggleMenuVis(void)
|
||||
|
@ -2168,6 +2178,15 @@ void consoleWin_t::openMsgLogWin(void)
|
|||
return;
|
||||
}
|
||||
|
||||
void consoleWin_t::openOnlineDocs(void)
|
||||
{
|
||||
if ( QDesktopServices::openUrl( QUrl("http://fceux.com/web/help/fceux.html") ) == false )
|
||||
{
|
||||
QueueErrorMsgWindow("Error: Failed to open link to: http://fceux.com/web/help/fceux.html");
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
#if defined(__linux__) || defined(__APPLE__) || defined(__unix__)
|
||||
int consoleWin_t::setNicePriority( int value )
|
||||
{
|
||||
|
|
|
@ -194,6 +194,7 @@ class consoleWin_t : public QMainWindow
|
|||
void closeROMCB(void);
|
||||
void aboutFCEUX(void);
|
||||
void aboutQt(void);
|
||||
void openOnlineDocs(void);
|
||||
void openMsgLogWin(void);
|
||||
void openInputConfWin(void);
|
||||
void openGameSndConfWin(void);
|
||||
|
|
Loading…
Reference in New Issue