mirror of
https://github.com/obsproject/obs-studio.git
synced 2024-07-19 17:49:14 +00:00
UI: Add Help menu action to show What's New dialog
This commit is contained in:
parent
5083c2a2e2
commit
09b6786f1a
|
@ -819,6 +819,7 @@ Basic.MainMenu.Help="&Help"
|
|||
Basic.MainMenu.Help.HelpPortal="Help &Portal"
|
||||
Basic.MainMenu.Help.Website="Visit &Website"
|
||||
Basic.MainMenu.Help.Discord="Join &Discord Server"
|
||||
Basic.MainMenu.Help.WhatsNew="What's New"
|
||||
Basic.MainMenu.Help.Logs="&Log Files"
|
||||
Basic.MainMenu.Help.Logs.ShowLogs="&Show Log Files"
|
||||
Basic.MainMenu.Help.Logs.UploadCurrentLog="Upload &Current Log File"
|
||||
|
|
|
@ -532,6 +532,7 @@
|
|||
<addaction name="separator"/>
|
||||
<addaction name="actionRepair"/>
|
||||
<addaction name="actionCheckForUpdates"/>
|
||||
<addaction name="actionShowWhatsNew"/>
|
||||
<addaction name="actionShowAbout"/>
|
||||
<addaction name="actionShowMacPermissions"/>
|
||||
<addaction name="separator"/>
|
||||
|
@ -2201,6 +2202,11 @@
|
|||
<string>Basic.MainMenu.Help.Discord</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionShowWhatsNew">
|
||||
<property name="text">
|
||||
<string>Basic.MainMenu.Help.WhatsNew</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionShowAbout">
|
||||
<property name="text">
|
||||
<string>Basic.MainMenu.Help.About</string>
|
||||
|
|
|
@ -2176,6 +2176,11 @@ void OBSBasic::OBSInit()
|
|||
}
|
||||
#endif
|
||||
|
||||
#ifndef WHATSNEW_ENABLED
|
||||
delete ui->actionShowWhatsNew;
|
||||
ui->actionShowWhatsNew = nullptr;
|
||||
#endif
|
||||
|
||||
UpdatePreviewProgramIndicators();
|
||||
OnFirstLoad();
|
||||
|
||||
|
@ -7964,6 +7969,25 @@ void OBSBasic::on_actionDiscord_triggered()
|
|||
QDesktopServices::openUrl(url);
|
||||
}
|
||||
|
||||
void OBSBasic::on_actionShowWhatsNew_triggered()
|
||||
{
|
||||
#ifdef WHATSNEW_ENABLED
|
||||
if (introCheckThread && introCheckThread->isRunning())
|
||||
return;
|
||||
if (!cef)
|
||||
return;
|
||||
|
||||
config_set_int(App()->GlobalConfig(), "General", "InfoIncrement", -1);
|
||||
|
||||
WhatsNewInfoThread *wnit = new WhatsNewInfoThread();
|
||||
connect(wnit, &WhatsNewInfoThread::Result, this,
|
||||
&OBSBasic::ReceivedIntroJson, Qt::QueuedConnection);
|
||||
|
||||
introCheckThread.reset(wnit);
|
||||
introCheckThread->start();
|
||||
#endif
|
||||
}
|
||||
|
||||
void OBSBasic::on_actionShowSettingsFolder_triggered()
|
||||
{
|
||||
char path[512];
|
||||
|
|
|
@ -1034,6 +1034,7 @@ private slots:
|
|||
void on_actionViewCurrentLog_triggered();
|
||||
void on_actionCheckForUpdates_triggered();
|
||||
void on_actionRepair_triggered();
|
||||
void on_actionShowWhatsNew_triggered();
|
||||
|
||||
void on_actionShowCrashLogs_triggered();
|
||||
void on_actionUploadLastCrashLog_triggered();
|
||||
|
|
Loading…
Reference in a new issue