logic: IDE Communication
Network code and controller added to communicate with IDE plugins. Does not include GUI integration though.
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
#include "IDECommunicationController.h"
|
||||
|
||||
#include "utility/messaging/type/MessageActivateTokens.h"
|
||||
#include "utility/logging/logging.h"
|
||||
|
||||
#include "component/controller/helper/NetworkProtocolHelper.h"
|
||||
|
||||
IDECommunicationController::IDECommunicationController()
|
||||
{
|
||||
}
|
||||
|
||||
IDECommunicationController::~IDECommunicationController()
|
||||
{
|
||||
}
|
||||
|
||||
void IDECommunicationController::handleIncomingMessage(const std::string& message)
|
||||
{
|
||||
LOG_WARNING_STREAM(<< message);
|
||||
|
||||
NetworkProtocolHelper::NetworkMessage parsedMessage = NetworkProtocolHelper::parseMessage(message);
|
||||
|
||||
if (parsedMessage.valid)
|
||||
{
|
||||
// TODO: set active token
|
||||
}
|
||||
}
|
||||
|
||||
void IDECommunicationController::handleMessage(MessageMoveIDECursor* message)
|
||||
{
|
||||
std::string networkMessage = NetworkProtocolHelper::buildMessage(message->FilePosition, message->Row, message->Column);
|
||||
|
||||
sendMessage(networkMessage);
|
||||
}
|
||||
Reference in New Issue
Block a user