Add Discord Rich Presence support

This commit is contained in:
Sleepy Flower Girl
2018-05-27 00:24:13 -04:00
parent f568e41fac
commit d5303ddf0b
18 changed files with 203 additions and 8 deletions

View File

@ -91,6 +91,7 @@
#include "InputCommon/ControllerInterface/ControllerInterface.h"
#include "UICommon/DiscordPresence.h"
#include "UICommon/GameFile.h"
#include "UICommon/UICommon.h"
@ -744,6 +745,7 @@ void CFrame::StartGame(std::unique_ptr<BootParameters> boot)
else
{
EnableScreenSaver(false);
Discord::UpdateDiscordPresence();
// We need this specifically to support setting the focus properly when using
// the 'render to main window' feature on Windows
@ -930,6 +932,7 @@ void CFrame::OnStopped()
wxPostEvent(GetMenuBar(), wxCommandEvent{DOLPHIN_EVT_UPDATE_LOAD_WII_MENU_ITEM});
EnableScreenSaver(true);
Discord::UpdateDiscordPresence();
m_render_frame->SetTitle(StrToWxStr(Common::scm_rev_str));