mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-13 19:49:51 +01:00
33 lines
656 B
C++
33 lines
656 B
C++
#pragma once
|
|
|
|
#include <QThread>
|
|
|
|
namespace chatterino {
|
|
|
|
class NativeMessagingManager
|
|
{
|
|
public:
|
|
// fourtf: don't add this class to the application class
|
|
NativeMessagingManager();
|
|
|
|
~NativeMessagingManager() = delete;
|
|
|
|
class ReceiverThread : public QThread
|
|
{
|
|
public:
|
|
void run() override;
|
|
|
|
private:
|
|
void handleMessage(const QJsonObject &root);
|
|
};
|
|
|
|
void writeByteArray(QByteArray a);
|
|
void registerHost();
|
|
void openGuiMessageQueue();
|
|
void sendToGuiProcess(const QByteArray &array);
|
|
|
|
static std::string &getGuiMessageQueueName();
|
|
};
|
|
|
|
} // namespace chatterino
|