aboutsummaryrefslogtreecommitdiff
path: root/include/discord_rpc.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/discord_rpc.h')
-rw-r--r--include/discord_rpc.h56
1 files changed, 29 insertions, 27 deletions
diff --git a/include/discord_rpc.h b/include/discord_rpc.h
index 737f2f6..6bd4404 100644
--- a/include/discord_rpc.h
+++ b/include/discord_rpc.h
@@ -24,37 +24,37 @@ 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;
+ 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 DiscordUser {
- const char *userId;
- const char *username;
- const char *discriminator;
- const char *avatar;
+ const char *userId;
+ const char *username;
+ const char *discriminator;
+ const char *avatar;
} DiscordUser;
typedef struct DiscordEventHandlers {
- void (*ready)(const DiscordUser *request);
- 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 DiscordUser *request);
+ void (*ready)(const DiscordUser *request);
+ 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 DiscordUser *request);
} DiscordEventHandlers;
#define DISCORD_REPLY_NO 0
@@ -70,7 +70,8 @@ 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 */
+/* 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
@@ -78,7 +79,8 @@ DISCORD_EXPORT void Discord_UpdateConnection(void);
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);
+DISCORD_EXPORT void Discord_Respond(const char *userid,
+ /* DISCORD_REPLY_ */ int reply);
DISCORD_EXPORT void Discord_UpdateHandlers(DiscordEventHandlers *handlers);