Merge pull request #6983 from yourWaifu/add-discord-rpc-support

Add Discord Rich Presence support
This commit is contained in:
Pierre Bourdon
2018-06-25 00:06:27 +02:00
committed by GitHub
84 changed files with 18060 additions and 4 deletions

View File

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