mirror of
https://github.com/libretro/ppsspp.git
synced 2025-02-21 17:30:46 +00:00
Basic Discord presence integration.
This commit is contained in:
parent
eddaf97938
commit
785858dbf8
@ -396,6 +396,7 @@ static ConfigSetting generalSettings[] = {
|
||||
ConfigSetting("CheckForNewVersion", &g_Config.bCheckForNewVersion, true),
|
||||
ConfigSetting("Language", &g_Config.sLanguageIni, &DefaultLangRegion),
|
||||
ConfigSetting("ForceLagSync", &g_Config.bForceLagSync, false, true, true),
|
||||
ConfigSetting("DiscordPresence", &g_Config.bDiscordPresence, true, true, false), // Or maybe it makes sense to have it per-game? Race conditions abound...
|
||||
|
||||
ReportedConfigSetting("NumWorkerThreads", &g_Config.iNumWorkerThreads, &DefaultNumWorkers, true, true),
|
||||
ConfigSetting("AutoLoadSaveState", &g_Config.iAutoLoadSaveState, 0, true, true),
|
||||
|
@ -117,6 +117,8 @@ public:
|
||||
std::vector<std::string> vPinnedPaths;
|
||||
std::string sLanguageIni;
|
||||
|
||||
bool bDiscordPresence; // Enables setting the Discord presence to the current game (or menu)
|
||||
|
||||
// GFX
|
||||
int iGPUBackend;
|
||||
// We have separate device parameters for each backend so it doesn't get erased if you switch backends.
|
||||
|
114
UI/DiscordIntegration.cpp
Normal file
114
UI/DiscordIntegration.cpp
Normal file
@ -0,0 +1,114 @@
|
||||
#include <ctime>
|
||||
#include <cassert>
|
||||
|
||||
#include "ppsspp_config.h"
|
||||
#include "Common/Log.h"
|
||||
#include "Core/Config.h"
|
||||
#include "DiscordIntegration.h"
|
||||
|
||||
#include "ext/discord-rpc/include/discord_rpc.h"
|
||||
|
||||
// TODO: Enable on more platforms. Make optional.
|
||||
|
||||
#ifdef _WIN32
|
||||
|
||||
const bool g_DiscordEnabled = true;
|
||||
|
||||
#else
|
||||
|
||||
const bool g_DiscordEnabled = true;
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
Discord g_Discord;
|
||||
|
||||
static const char *ppsspp_app_id = "423397985041383434";
|
||||
|
||||
// No context argument? What?
|
||||
static void handleDiscordError(int errCode, const char *message) {
|
||||
ERROR_LOG(SYSTEM, "Discord error code %d: '%s'", message);
|
||||
}
|
||||
|
||||
Discord::~Discord() {
|
||||
assert(!initialized_);
|
||||
}
|
||||
|
||||
bool Discord::IsEnabled() const {
|
||||
return g_DiscordEnabled && g_Config.bDiscordPresence;
|
||||
}
|
||||
|
||||
void Discord::Init() {
|
||||
assert(IsEnabled());
|
||||
assert(!initialized_);
|
||||
|
||||
DiscordEventHandlers eventHandlers{};
|
||||
eventHandlers.errored = &handleDiscordError;
|
||||
Discord_Initialize(ppsspp_app_id, &eventHandlers, 0, nullptr);
|
||||
|
||||
initialized_ = true;
|
||||
}
|
||||
|
||||
void Discord::Shutdown() {
|
||||
assert(initialized_);
|
||||
Discord_Shutdown();
|
||||
initialized_ = false;
|
||||
}
|
||||
|
||||
void Discord::Update() {
|
||||
if (!IsEnabled()) {
|
||||
if (initialized_) {
|
||||
Shutdown();
|
||||
}
|
||||
return;
|
||||
} else {
|
||||
if (!initialized_) {
|
||||
Init();
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef DISCORD_DISABLE_IO_THREAD
|
||||
Discord_UpdateConnection();
|
||||
#endif
|
||||
Discord_RunCallbacks();
|
||||
}
|
||||
|
||||
void Discord::SetPresenceGame(const char *gameTitle) {
|
||||
if (!IsEnabled())
|
||||
return;
|
||||
|
||||
if (!initialized_) {
|
||||
Init();
|
||||
}
|
||||
|
||||
DiscordRichPresence discordPresence{};
|
||||
discordPresence.state = gameTitle;
|
||||
discordPresence.details = "Playing";
|
||||
discordPresence.startTimestamp = time(0);
|
||||
#ifdef GOLD
|
||||
discordPresence.largeImageKey = "icon_gold_png";
|
||||
#else
|
||||
discordPresence.largeImageKey = "icon_regular_png";
|
||||
#endif
|
||||
Discord_UpdatePresence(&discordPresence);
|
||||
}
|
||||
|
||||
void Discord::SetPresenceMenu() {
|
||||
if (!IsEnabled())
|
||||
return;
|
||||
|
||||
if (!initialized_) {
|
||||
Init();
|
||||
}
|
||||
|
||||
DiscordRichPresence discordPresence{};
|
||||
discordPresence.state = "In menu";
|
||||
discordPresence.details = "";
|
||||
discordPresence.startTimestamp = time(0);
|
||||
#ifdef GOLD
|
||||
discordPresence.largeImageKey = "icon_gold_png";
|
||||
#else
|
||||
discordPresence.largeImageKey = "icon_regular_png";
|
||||
#endif
|
||||
Discord_UpdatePresence(&discordPresence);
|
||||
}
|
28
UI/DiscordIntegration.h
Normal file
28
UI/DiscordIntegration.h
Normal file
@ -0,0 +1,28 @@
|
||||
#pragma once
|
||||
|
||||
#include <string>
|
||||
|
||||
// Simple wrapper around the Discord api.
|
||||
|
||||
// All platforms should call it, but we only actually take action on
|
||||
// platforms where we want it enabled (only PC initially).
|
||||
|
||||
// All you need to call is FrameCallback, Shutdown, and UpdatePresence.
|
||||
|
||||
class Discord {
|
||||
public:
|
||||
~Discord();
|
||||
void Update(); // Call every frame or at least regularly. Will initialize if necessary.
|
||||
void Shutdown();
|
||||
|
||||
void SetPresenceGame(const char *gameTitle);
|
||||
void SetPresenceMenu();
|
||||
|
||||
private:
|
||||
void Init();
|
||||
bool IsEnabled() const;
|
||||
|
||||
bool initialized_ = false;
|
||||
};
|
||||
|
||||
extern Discord g_Discord;
|
@ -77,6 +77,7 @@
|
||||
#include "UI/GameSettingsScreen.h"
|
||||
#include "UI/InstallZipScreen.h"
|
||||
#include "UI/ProfilerDraw.h"
|
||||
#include "UI/DiscordIntegration.h"
|
||||
|
||||
#if defined(_WIN32) && !PPSSPP_PLATFORM(UWP)
|
||||
#include "Windows/MainWindow.h"
|
||||
@ -192,6 +193,10 @@ void EmuScreen::bootGame(const std::string &filename) {
|
||||
g_Config.loadGameConfig(info->id);
|
||||
// Reset views in case controls are in a different place.
|
||||
RecreateViews();
|
||||
|
||||
g_Discord.SetPresenceGame(info->GetTitle().c_str());
|
||||
} else {
|
||||
g_Discord.SetPresenceGame("(unknown)");
|
||||
}
|
||||
|
||||
invalid_ = true;
|
||||
@ -333,6 +338,7 @@ EmuScreen::~EmuScreen() {
|
||||
startDumping = false;
|
||||
}
|
||||
#endif
|
||||
g_Discord.SetPresenceMenu();
|
||||
}
|
||||
|
||||
void EmuScreen::dialogFinished(const Screen *dialog, DialogResult result) {
|
||||
|
@ -642,6 +642,7 @@ void GameSettingsScreen::CreateViews() {
|
||||
networkingSettings->Add(new Choice(n->T("Adhoc Multiplayer forum")))->OnClick.Handle(this, &GameSettingsScreen::OnAdhocGuides);
|
||||
|
||||
networkingSettings->Add(new CheckBox(&g_Config.bEnableWlan, n->T("Enable networking", "Enable networking/wlan (beta)")));
|
||||
networkingSettings->Add(new CheckBox(&g_Config.bDiscordPresence, n->T("Send Discord Presence information")));
|
||||
|
||||
#if !defined(MOBILE_DEVICE) && !defined(USING_QT_UI)
|
||||
networkingSettings->Add(new PopupTextInputChoice(&g_Config.proAdhocServer, n->T("Change proAdhocServer Address"), "", 255, screenManager()));
|
||||
|
@ -98,6 +98,7 @@
|
||||
#include "UI/TiltEventProcessor.h"
|
||||
#include "UI/BackgroundAudio.h"
|
||||
#include "UI/TextureUtil.h"
|
||||
#include "UI/DiscordIntegration.h"
|
||||
|
||||
#if !defined(MOBILE_DEVICE)
|
||||
#include "Common/KeyMap.h"
|
||||
@ -352,6 +353,8 @@ void NativeInit(int argc, const char *argv[], const char *savegame_dir, const ch
|
||||
InitFastMath(cpu_info.bNEON);
|
||||
SetupAudioFormats();
|
||||
|
||||
g_Discord.SetPresenceMenu();
|
||||
|
||||
// Make sure UI state is MENU.
|
||||
ResetUIState();
|
||||
|
||||
@ -1028,6 +1031,8 @@ void NativeUpdate() {
|
||||
|
||||
g_DownloadManager.Update();
|
||||
screenManager->update();
|
||||
|
||||
g_Discord.Update();
|
||||
}
|
||||
|
||||
bool NativeIsAtTopLevel() {
|
||||
@ -1213,6 +1218,8 @@ void NativeShutdown() {
|
||||
|
||||
net::Shutdown();
|
||||
|
||||
g_Discord.Shutdown();
|
||||
|
||||
delete logger;
|
||||
logger = nullptr;
|
||||
|
||||
|
@ -24,6 +24,7 @@
|
||||
<ClCompile Include="ControlMappingScreen.cpp" />
|
||||
<ClCompile Include="CwCheatScreen.cpp" />
|
||||
<ClCompile Include="DevScreens.cpp" />
|
||||
<ClCompile Include="DiscordIntegration.cpp" />
|
||||
<ClCompile Include="DisplayLayoutEditor.cpp" />
|
||||
<ClCompile Include="DisplayLayoutScreen.cpp" />
|
||||
<ClCompile Include="EmuScreen.cpp" />
|
||||
@ -54,6 +55,7 @@
|
||||
<ClInclude Include="ComboKeyMappingScreen.h" />
|
||||
<ClInclude Include="ControlMappingScreen.h" />
|
||||
<ClInclude Include="DevScreens.h" />
|
||||
<ClInclude Include="DiscordIntegration.h" />
|
||||
<ClInclude Include="DisplayLayoutEditor.h" />
|
||||
<ClInclude Include="DisplayLayoutScreen.h" />
|
||||
<ClInclude Include="EmuScreen.h" />
|
||||
@ -80,11 +82,17 @@
|
||||
<ClInclude Include="InstallZipScreen.h" />
|
||||
<ClInclude Include="ui_atlas.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\ext\discord-rpc-build\discord-rpc.vcxproj">
|
||||
<Project>{beb0a821-3c7f-410f-a525-63afbc69bf8f}</Project>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{004B8D11-2BE3-4BD9-AB40-2BE04CF2096F}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>UI</RootNamespace>
|
||||
<WindowsTargetPlatformVersion></WindowsTargetPlatformVersion>
|
||||
<WindowsTargetPlatformVersion>
|
||||
</WindowsTargetPlatformVersion>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
|
@ -70,6 +70,7 @@
|
||||
<Filter>Screens</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="TextureUtil.cpp" />
|
||||
<ClCompile Include="DiscordIntegration.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="GameInfoCache.h" />
|
||||
@ -141,6 +142,7 @@
|
||||
<Filter>Screens</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="TextureUtil.h" />
|
||||
<ClInclude Include="DiscordIntegration.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Filter Include="Screens">
|
||||
|
@ -913,7 +913,7 @@ namespace MainWindow
|
||||
InputDevice::StopPolling();
|
||||
MainThread_Stop();
|
||||
coreState = CORE_POWERUP;
|
||||
ResetUIState();
|
||||
UpdateUIState(UISTATE_MENU);
|
||||
MainThread_Start(g_Config.iGPUBackend == (int)GPUBackend::OPENGL);
|
||||
InputDevice::BeginPolling();
|
||||
break;
|
||||
|
@ -1,6 +1,6 @@
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio 14
|
||||
VisualStudioVersion = 14.0.25420.1
|
||||
# Visual Studio 15
|
||||
VisualStudioVersion = 15.0.27703.2026
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "PPSSPPWindows", "PPSSPP.vcxproj", "{567AF8DB-42C1-4D08-96CD-D70A2DFEFC6B}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
@ -77,6 +77,8 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "glslang", "..\ext\glslang.v
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "SPIRV-Cross", "..\ext\SPIRV-Cross.vcxproj", "{4328A62C-F1E9-47ED-B816-A1A81DAF4363}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "discord-rpc", "..\ext\discord-rpc-build\discord-rpc.vcxproj", "{BEB0A821-3C7F-410F-A525-63AFBC69BF8F}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Win32 = Debug|Win32
|
||||
@ -105,7 +107,6 @@ Global
|
||||
{F761046E-6C38-4428-A5F1-38391A37BB34}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{F761046E-6C38-4428-A5F1-38391A37BB34}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{F761046E-6C38-4428-A5F1-38391A37BB34}.Debug|x64.Build.0 = Debug|x64
|
||||
{F761046E-6C38-4428-A5F1-38391A37BB34}.Release|ARM.ActiveCfg = Release|Win32
|
||||
{F761046E-6C38-4428-A5F1-38391A37BB34}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{F761046E-6C38-4428-A5F1-38391A37BB34}.Release|Win32.Build.0 = Release|Win32
|
||||
{F761046E-6C38-4428-A5F1-38391A37BB34}.Release|x64.ActiveCfg = Release|x64
|
||||
@ -114,7 +115,6 @@ Global
|
||||
{457F45D2-556F-47BC-A31D-AFF0D15BEAED}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{457F45D2-556F-47BC-A31D-AFF0D15BEAED}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{457F45D2-556F-47BC-A31D-AFF0D15BEAED}.Debug|x64.Build.0 = Debug|x64
|
||||
{457F45D2-556F-47BC-A31D-AFF0D15BEAED}.Release|ARM.ActiveCfg = Release|Win32
|
||||
{457F45D2-556F-47BC-A31D-AFF0D15BEAED}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{457F45D2-556F-47BC-A31D-AFF0D15BEAED}.Release|Win32.Build.0 = Release|Win32
|
||||
{457F45D2-556F-47BC-A31D-AFF0D15BEAED}.Release|x64.ActiveCfg = Release|x64
|
||||
@ -191,8 +191,19 @@ Global
|
||||
{4328A62C-F1E9-47ED-B816-A1A81DAF4363}.Release|Win32.Build.0 = Release|Win32
|
||||
{4328A62C-F1E9-47ED-B816-A1A81DAF4363}.Release|x64.ActiveCfg = Release|x64
|
||||
{4328A62C-F1E9-47ED-B816-A1A81DAF4363}.Release|x64.Build.0 = Release|x64
|
||||
{BEB0A821-3C7F-410F-A525-63AFBC69BF8F}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{BEB0A821-3C7F-410F-A525-63AFBC69BF8F}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{BEB0A821-3C7F-410F-A525-63AFBC69BF8F}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{BEB0A821-3C7F-410F-A525-63AFBC69BF8F}.Debug|x64.Build.0 = Debug|x64
|
||||
{BEB0A821-3C7F-410F-A525-63AFBC69BF8F}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{BEB0A821-3C7F-410F-A525-63AFBC69BF8F}.Release|Win32.Build.0 = Release|Win32
|
||||
{BEB0A821-3C7F-410F-A525-63AFBC69BF8F}.Release|x64.ActiveCfg = Release|x64
|
||||
{BEB0A821-3C7F-410F-A525-63AFBC69BF8F}.Release|x64.Build.0 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {2FD47774-A031-48F4-B645-A49A3140A29B}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
||||
|
176
ext/discord-rpc-build/discord-rpc.vcxproj
Normal file
176
ext/discord-rpc-build/discord-rpc.vcxproj
Normal file
@ -0,0 +1,176 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\discord-rpc\include\discord_register.h" />
|
||||
<ClInclude Include="..\discord-rpc\include\discord_rpc.h" />
|
||||
<ClInclude Include="..\discord-rpc\src\backoff.h" />
|
||||
<ClInclude Include="..\discord-rpc\src\connection.h" />
|
||||
<ClInclude Include="..\discord-rpc\src\msg_queue.h" />
|
||||
<ClInclude Include="..\discord-rpc\src\rpc_connection.h" />
|
||||
<ClInclude Include="..\discord-rpc\src\serialization.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Text Include="..\discord-rpc\src\CMakeLists.txt" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\discord-rpc\src\connection_win.cpp" />
|
||||
<ClCompile Include="..\discord-rpc\src\discord_register_win.cpp" />
|
||||
<ClCompile Include="..\discord-rpc\src\discord_rpc.cpp" />
|
||||
<ClCompile Include="..\discord-rpc\src\dllmain.cpp" />
|
||||
<ClCompile Include="..\discord-rpc\src\rpc_connection.cpp" />
|
||||
<ClCompile Include="..\discord-rpc\src\serialization.cpp" />
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<VCProjectVersion>15.0</VCProjectVersion>
|
||||
<ProjectGuid>{BEB0A821-3C7F-410F-A525-63AFBC69BF8F}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>discordrpc</RootNamespace>
|
||||
<WindowsTargetPlatformVersion>10.0.17134.0</WindowsTargetPlatformVersion>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="Shared">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<LinkIncremental>true</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<LinkIncremental>true</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<PreprocessorDefinitions>NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalIncludeDirectories>..\discord-rpc\include;..\discord-rpc\src;..\rapidjson\include</AdditionalIncludeDirectories>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalIncludeDirectories>..\discord-rpc\include;..\discord-rpc\src;..\rapidjson\include</AdditionalIncludeDirectories>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<PreprocessorDefinitions>_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalIncludeDirectories>..\discord-rpc\include;..\discord-rpc\src;..\rapidjson\include</AdditionalIncludeDirectories>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalIncludeDirectories>..\discord-rpc\include;..\discord-rpc\src;..\rapidjson\include</AdditionalIncludeDirectories>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
23
ext/discord-rpc-build/discord-rpc.vcxproj.filters
Normal file
23
ext/discord-rpc-build/discord-rpc.vcxproj.filters
Normal file
@ -0,0 +1,23 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\discord-rpc\src\backoff.h" />
|
||||
<ClInclude Include="..\discord-rpc\src\connection.h" />
|
||||
<ClInclude Include="..\discord-rpc\src\msg_queue.h" />
|
||||
<ClInclude Include="..\discord-rpc\src\rpc_connection.h" />
|
||||
<ClInclude Include="..\discord-rpc\src\serialization.h" />
|
||||
<ClInclude Include="..\discord-rpc\include\discord_register.h" />
|
||||
<ClInclude Include="..\discord-rpc\include\discord_rpc.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Text Include="..\discord-rpc\src\CMakeLists.txt" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\discord-rpc\src\connection_win.cpp" />
|
||||
<ClCompile Include="..\discord-rpc\src\discord_register_win.cpp" />
|
||||
<ClCompile Include="..\discord-rpc\src\discord_rpc.cpp" />
|
||||
<ClCompile Include="..\discord-rpc\src\dllmain.cpp" />
|
||||
<ClCompile Include="..\discord-rpc\src\rpc_connection.cpp" />
|
||||
<ClCompile Include="..\discord-rpc\src\serialization.cpp" />
|
||||
</ItemGroup>
|
||||
</Project>
|
Loading…
x
Reference in New Issue
Block a user