aboutsummaryrefslogtreecommitdiff
path: root/discord-rpc.h
diff options
context:
space:
mode:
authorDavid Skoland <davidskoland@gmail.com>2018-12-26 16:43:08 +0100
committerDavid Skoland <davidskoland@gmail.com>2018-12-26 16:43:08 +0100
commit00cfd2750d39795e4c205aee2a33b92b1da2524d (patch)
tree839c1129418ca8fefe41e6814917f9dabb6efa4b /discord-rpc.h
parent6f1bce5882676ea7affe717a2f5a00b8c3b7fe12 (diff)
moved headers into include and cpp files into src + logo into resource
Diffstat (limited to 'discord-rpc.h')
-rw-r--r--discord-rpc.h85
1 files changed, 0 insertions, 85 deletions
diff --git a/discord-rpc.h b/discord-rpc.h
deleted file mode 100644
index feb874b2..00000000
--- a/discord-rpc.h
+++ /dev/null
@@ -1,85 +0,0 @@
-#pragma once
-#include <stdint.h>
-
-// clang-format off
-
-#if defined(DISCORD_DYNAMIC_LIB)
-# if defined(_WIN32)
-# if defined(DISCORD_BUILDING_SDK)
-# define DISCORD_EXPORT __declspec(dllexport)
-# else
-# define DISCORD_EXPORT __declspec(dllimport)
-# endif
-# else
-# define DISCORD_EXPORT __attribute__((visibility("default")))
-# endif
-#else
-# define DISCORD_EXPORT
-#endif
-
-// clang-format on
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-typedef struct DiscordRichPresence {
- const char* state; /* max 128 bytes */
- const char* details; /* max 128 bytes */
- int64_t startTimestamp;
- int64_t endTimestamp;
- const char* largeImageKey; /* max 32 bytes */
- const char* largeImageText; /* max 128 bytes */
- const char* smallImageKey; /* max 32 bytes */
- const char* smallImageText; /* max 128 bytes */
- const char* partyId; /* max 128 bytes */
- int partySize;
- int partyMax;
- const char* matchSecret; /* max 128 bytes */
- const char* joinSecret; /* max 128 bytes */
- const char* spectateSecret; /* max 128 bytes */
- int8_t instance;
-} DiscordRichPresence;
-
-typedef struct DiscordJoinRequest {
- const char* userId;
- const char* username;
- const char* discriminator;
- const char* avatar;
-} DiscordJoinRequest;
-
-typedef struct DiscordEventHandlers {
- void (*ready)(void);
- void (*disconnected)(int errorCode, const char* message);
- void (*errored)(int errorCode, const char* message);
- void (*joinGame)(const char* joinSecret);
- void (*spectateGame)(const char* spectateSecret);
- void (*joinRequest)(const DiscordJoinRequest* request);
-} DiscordEventHandlers;
-
-#define DISCORD_REPLY_NO 0
-#define DISCORD_REPLY_YES 1
-#define DISCORD_REPLY_IGNORE 2
-
-DISCORD_EXPORT void Discord_Initialize(const char* applicationId,
- DiscordEventHandlers* handlers,
- int autoRegister,
- const char* optionalSteamId);
-DISCORD_EXPORT void Discord_Shutdown(void);
-
-/* checks for incoming messages, dispatches callbacks */
-DISCORD_EXPORT void Discord_RunCallbacks(void);
-
-/* If you disable the lib starting its own io thread, you'll need to call this from your own */
-#ifdef DISCORD_DISABLE_IO_THREAD
-DISCORD_EXPORT void Discord_UpdateConnection(void);
-#endif
-
-DISCORD_EXPORT void Discord_UpdatePresence(const DiscordRichPresence* presence);
-DISCORD_EXPORT void Discord_ClearPresence(void);
-
-DISCORD_EXPORT void Discord_Respond(const char* userid, /* DISCORD_REPLY_ */ int reply);
-
-#ifdef __cplusplus
-} /* extern "C" */
-#endif