summaryrefslogtreecommitdiff
path: root/src/discord/websocket.hpp
diff options
context:
space:
mode:
authorouwou <26526779+ouwou@users.noreply.github.com>2021-11-25 02:57:11 -0500
committerouwou <26526779+ouwou@users.noreply.github.com>2021-11-25 02:57:11 -0500
commit8c72d4c18d9c27ce1b5cd20f0cb98e5638c8becf (patch)
tree244f645e36250e103c54462091855aa78e8e3c20 /src/discord/websocket.hpp
parent0da913cd4a76aae1ca41abe5b1a51874c974d3aa (diff)
downloadabaddon-portaudio-8c72d4c18d9c27ce1b5cd20f0cb98e5638c8becf.tar.gz
abaddon-portaudio-8c72d4c18d9c27ce1b5cd20f0cb98e5638c8becf.zip
dont print identify message to console
mainly since i feel its only a matter of time before someone copy pastes it somewhere and itd be my fault also typedef -> using
Diffstat (limited to 'src/discord/websocket.hpp')
-rw-r--r--src/discord/websocket.hpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/discord/websocket.hpp b/src/discord/websocket.hpp
index e6a6489..26cd5d4 100644
--- a/src/discord/websocket.hpp
+++ b/src/discord/websocket.hpp
@@ -13,6 +13,9 @@ public:
void SetUserAgent(std::string agent);
+ bool GetPrintMessages() const noexcept;
+ void SetPrintMessages(bool show) noexcept;
+
void Send(const std::string &str);
void Send(const nlohmann::json &j);
void Stop();
@@ -26,9 +29,9 @@ private:
std::string m_agent;
public:
- typedef sigc::signal<void> type_signal_open;
- typedef sigc::signal<void, uint16_t> type_signal_close;
- typedef sigc::signal<void, std::string> type_signal_message;
+ using type_signal_open = sigc::signal<void>;
+ using type_signal_close = sigc::signal<void, uint16_t>;
+ using type_signal_message = sigc::signal<void, std::string>;
type_signal_open signal_open();
type_signal_close signal_close();
@@ -38,4 +41,6 @@ private:
type_signal_open m_signal_open;
type_signal_close m_signal_close;
type_signal_message m_signal_message;
+
+ bool m_print_messages = true;
};