2002-08-02 19:57:46 +00:00
|
|
|
/*
|
|
|
|
* synergy -- mouse and keyboard sharing utility
|
|
|
|
* Copyright (C) 2002 Chris Schoeneman
|
|
|
|
*
|
|
|
|
* This package is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public License
|
|
|
|
* found in the file COPYING that should have accompanied this file.
|
|
|
|
*
|
|
|
|
* This package is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*/
|
|
|
|
|
2002-07-10 20:18:32 +00:00
|
|
|
#include "CServerProxy.h"
|
2004-02-15 17:32:11 +00:00
|
|
|
#include "CClient.h"
|
|
|
|
#include "CClipboard.h"
|
2002-07-10 20:18:32 +00:00
|
|
|
#include "CProtocolUtil.h"
|
2002-12-23 14:47:44 +00:00
|
|
|
#include "OptionTypes.h"
|
2002-07-10 20:18:32 +00:00
|
|
|
#include "ProtocolTypes.h"
|
2004-02-15 17:32:11 +00:00
|
|
|
#include "IStream.h"
|
2002-07-10 20:18:32 +00:00
|
|
|
#include "CLog.h"
|
2004-02-15 17:32:11 +00:00
|
|
|
#include "IEventQueue.h"
|
|
|
|
#include "TMethodEventJob.h"
|
2002-07-10 20:18:32 +00:00
|
|
|
#include "XBase.h"
|
|
|
|
#include <memory>
|
|
|
|
|
|
|
|
//
|
|
|
|
// CServerProxy
|
|
|
|
//
|
|
|
|
|
2004-02-15 17:32:11 +00:00
|
|
|
CServerProxy::CServerProxy(CClient* client, IStream* stream) :
|
2002-07-10 20:18:32 +00:00
|
|
|
m_client(client),
|
2004-02-15 17:32:11 +00:00
|
|
|
m_stream(stream),
|
2003-02-22 16:20:23 +00:00
|
|
|
m_seqNum(0),
|
2004-02-15 17:32:11 +00:00
|
|
|
m_compressMouse(false),
|
2004-05-02 08:03:49 +00:00
|
|
|
m_compressMouseRelative(false),
|
|
|
|
m_xMouse(0),
|
|
|
|
m_yMouse(0),
|
|
|
|
m_dxMouse(0),
|
|
|
|
m_dyMouse(0),
|
2004-02-15 17:32:11 +00:00
|
|
|
m_ignoreMouse(false),
|
2007-06-17 11:19:18 +00:00
|
|
|
m_keepAliveAlarm(0.0),
|
|
|
|
m_keepAliveAlarmTimer(NULL),
|
2004-02-28 12:19:49 +00:00
|
|
|
m_parser(&CServerProxy::parseHandshakeMessage)
|
2002-07-10 20:18:32 +00:00
|
|
|
{
|
|
|
|
assert(m_client != NULL);
|
2004-02-15 17:32:11 +00:00
|
|
|
assert(m_stream != NULL);
|
2003-02-22 15:03:31 +00:00
|
|
|
|
|
|
|
// initialize modifier translation table
|
|
|
|
for (KeyModifierID id = 0; id < kKeyModifierIDLast; ++id)
|
|
|
|
m_modifierTranslationTable[id] = id;
|
2004-02-15 17:32:11 +00:00
|
|
|
|
|
|
|
// handle data on stream
|
|
|
|
EVENTQUEUE->adoptHandler(IStream::getInputReadyEvent(),
|
|
|
|
m_stream->getEventTarget(),
|
|
|
|
new TMethodEventJob<CServerProxy>(this,
|
2004-02-28 12:19:49 +00:00
|
|
|
&CServerProxy::handleData));
|
2004-02-15 17:32:11 +00:00
|
|
|
|
|
|
|
// send heartbeat
|
2007-06-17 11:19:18 +00:00
|
|
|
setKeepAliveRate(kKeepAliveRate);
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
CServerProxy::~CServerProxy()
|
|
|
|
{
|
2007-06-17 11:19:18 +00:00
|
|
|
setKeepAliveRate(-1.0);
|
2004-02-28 12:19:49 +00:00
|
|
|
EVENTQUEUE->removeHandler(IStream::getInputReadyEvent(),
|
|
|
|
m_stream->getEventTarget());
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
2004-02-15 17:32:11 +00:00
|
|
|
void
|
2007-06-17 11:19:18 +00:00
|
|
|
CServerProxy::resetKeepAliveAlarm()
|
2004-02-15 17:32:11 +00:00
|
|
|
{
|
2007-06-17 11:19:18 +00:00
|
|
|
if (m_keepAliveAlarmTimer != NULL) {
|
|
|
|
EVENTQUEUE->removeHandler(CEvent::kTimer, m_keepAliveAlarmTimer);
|
|
|
|
EVENTQUEUE->deleteTimer(m_keepAliveAlarmTimer);
|
|
|
|
m_keepAliveAlarmTimer = NULL;
|
|
|
|
}
|
|
|
|
if (m_keepAliveAlarm > 0.0) {
|
|
|
|
m_keepAliveAlarmTimer =
|
|
|
|
EVENTQUEUE->newOneShotTimer(m_keepAliveAlarm, NULL);
|
|
|
|
EVENTQUEUE->adoptHandler(CEvent::kTimer, m_keepAliveAlarmTimer,
|
2004-02-15 17:32:11 +00:00
|
|
|
new TMethodEventJob<CServerProxy>(this,
|
2007-06-17 11:19:18 +00:00
|
|
|
&CServerProxy::handleKeepAliveAlarm));
|
2004-02-15 17:32:11 +00:00
|
|
|
}
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2007-06-17 11:19:18 +00:00
|
|
|
void
|
|
|
|
CServerProxy::setKeepAliveRate(double rate)
|
|
|
|
{
|
|
|
|
m_keepAliveAlarm = rate * kKeepAlivesUntilDeath;
|
|
|
|
resetKeepAliveAlarm();
|
|
|
|
}
|
|
|
|
|
2004-02-15 17:32:11 +00:00
|
|
|
void
|
2004-02-28 12:19:49 +00:00
|
|
|
CServerProxy::handleData(const CEvent&, void*)
|
2004-02-15 17:32:11 +00:00
|
|
|
{
|
2004-02-28 12:19:49 +00:00
|
|
|
// handle messages until there are no more. first read message code.
|
|
|
|
UInt8 code[4];
|
|
|
|
UInt32 n = m_stream->read(code, 4);
|
|
|
|
while (n != 0) {
|
|
|
|
// verify we got an entire code
|
2004-02-15 17:32:11 +00:00
|
|
|
if (n != 4) {
|
2004-02-28 12:19:49 +00:00
|
|
|
LOG((CLOG_ERR "incomplete message from server: %d bytes", n));
|
2004-02-15 17:32:11 +00:00
|
|
|
m_client->disconnect("incomplete message from server");
|
|
|
|
return;
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-15 17:32:11 +00:00
|
|
|
// parse message
|
|
|
|
LOG((CLOG_DEBUG2 "msg from server: %c%c%c%c", code[0], code[1], code[2], code[3]));
|
2004-02-28 12:19:49 +00:00
|
|
|
switch ((this->*m_parser)(code)) {
|
|
|
|
case kOkay:
|
|
|
|
break;
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
case kUnknown:
|
2007-06-17 11:19:18 +00:00
|
|
|
LOG((CLOG_ERR "invalid message from server: %c%c%c%c", code[0], code[1], code[2], code[3]));
|
2004-02-28 12:19:49 +00:00
|
|
|
m_client->disconnect("invalid message from server");
|
|
|
|
return;
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
case kDisconnect:
|
|
|
|
return;
|
2004-02-15 17:32:11 +00:00
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
// next message
|
|
|
|
n = m_stream->read(code, 4);
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
flushCompressedMouse();
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
CServerProxy::EResult
|
|
|
|
CServerProxy::parseHandshakeMessage(const UInt8* code)
|
|
|
|
{
|
|
|
|
if (memcmp(code, kMsgQInfo, 4) == 0) {
|
|
|
|
queryInfo();
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
else if (memcmp(code, kMsgCInfoAck, 4) == 0) {
|
|
|
|
infoAcknowledgment();
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 16:00:54 +00:00
|
|
|
else if (memcmp(code, kMsgDSetOptions, 4) == 0) {
|
|
|
|
setOptions();
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
// handshake is complete
|
|
|
|
m_parser = &CServerProxy::parseMessage;
|
2004-03-13 17:16:24 +00:00
|
|
|
m_client->handshakeComplete();
|
2004-02-28 12:19:49 +00:00
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 16:00:54 +00:00
|
|
|
else if (memcmp(code, kMsgCResetOptions, 4) == 0) {
|
|
|
|
resetOptions();
|
|
|
|
}
|
|
|
|
|
2007-06-17 11:19:18 +00:00
|
|
|
else if (memcmp(code, kMsgCKeepAlive, 4) == 0) {
|
|
|
|
// echo keep alives and reset alarm
|
|
|
|
CProtocolUtil::writef(m_stream, kMsgCKeepAlive);
|
|
|
|
resetKeepAliveAlarm();
|
|
|
|
}
|
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
else if (memcmp(code, kMsgCNoop, 4) == 0) {
|
|
|
|
// accept and discard no-op
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
else if (memcmp(code, kMsgCClose, 4) == 0) {
|
|
|
|
// server wants us to hangup
|
|
|
|
LOG((CLOG_DEBUG1 "recv close"));
|
|
|
|
m_client->disconnect(NULL);
|
|
|
|
return kDisconnect;
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
else if (memcmp(code, kMsgEIncompatible, 4) == 0) {
|
|
|
|
SInt32 major, minor;
|
|
|
|
CProtocolUtil::readf(m_stream,
|
|
|
|
kMsgEIncompatible + 4, &major, &minor);
|
|
|
|
LOG((CLOG_ERR "server has incompatible version %d.%d", major, minor));
|
|
|
|
m_client->disconnect("server has incompatible version");
|
|
|
|
return kDisconnect;
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
else if (memcmp(code, kMsgEBusy, 4) == 0) {
|
|
|
|
LOG((CLOG_ERR "server already has a connected client with name \"%s\"", m_client->getName().c_str()));
|
|
|
|
m_client->disconnect("server already has a connected client with our name");
|
|
|
|
return kDisconnect;
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
else if (memcmp(code, kMsgEUnknown, 4) == 0) {
|
|
|
|
LOG((CLOG_ERR "server refused client with name \"%s\"", m_client->getName().c_str()));
|
|
|
|
m_client->disconnect("server refused client with our name");
|
|
|
|
return kDisconnect;
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
else if (memcmp(code, kMsgEBad, 4) == 0) {
|
|
|
|
LOG((CLOG_ERR "server disconnected due to a protocol error"));
|
|
|
|
m_client->disconnect("server reported a protocol error");
|
|
|
|
return kDisconnect;
|
|
|
|
}
|
|
|
|
else {
|
|
|
|
return kUnknown;
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
return kOkay;
|
|
|
|
}
|
2002-12-23 14:47:44 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
CServerProxy::EResult
|
|
|
|
CServerProxy::parseMessage(const UInt8* code)
|
|
|
|
{
|
|
|
|
if (memcmp(code, kMsgDMouseMove, 4) == 0) {
|
|
|
|
mouseMove();
|
|
|
|
}
|
2002-12-23 14:47:44 +00:00
|
|
|
|
2004-05-02 08:03:49 +00:00
|
|
|
else if (memcmp(code, kMsgDMouseRelMove, 4) == 0) {
|
|
|
|
mouseRelativeMove();
|
|
|
|
}
|
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
else if (memcmp(code, kMsgDMouseWheel, 4) == 0) {
|
|
|
|
mouseWheel();
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
else if (memcmp(code, kMsgDKeyDown, 4) == 0) {
|
|
|
|
keyDown();
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
else if (memcmp(code, kMsgDKeyUp, 4) == 0) {
|
|
|
|
keyUp();
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
else if (memcmp(code, kMsgDMouseDown, 4) == 0) {
|
|
|
|
mouseDown();
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
else if (memcmp(code, kMsgDMouseUp, 4) == 0) {
|
|
|
|
mouseUp();
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
else if (memcmp(code, kMsgDKeyRepeat, 4) == 0) {
|
|
|
|
keyRepeat();
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
2004-02-28 12:19:49 +00:00
|
|
|
|
2007-06-17 11:19:18 +00:00
|
|
|
else if (memcmp(code, kMsgCKeepAlive, 4) == 0) {
|
|
|
|
// echo keep alives and reset alarm
|
|
|
|
CProtocolUtil::writef(m_stream, kMsgCKeepAlive);
|
|
|
|
resetKeepAliveAlarm();
|
|
|
|
}
|
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
else if (memcmp(code, kMsgCNoop, 4) == 0) {
|
|
|
|
// accept and discard no-op
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (memcmp(code, kMsgCEnter, 4) == 0) {
|
|
|
|
enter();
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (memcmp(code, kMsgCLeave, 4) == 0) {
|
|
|
|
leave();
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (memcmp(code, kMsgCClipboard, 4) == 0) {
|
|
|
|
grabClipboard();
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (memcmp(code, kMsgCScreenSaver, 4) == 0) {
|
|
|
|
screensaver();
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (memcmp(code, kMsgQInfo, 4) == 0) {
|
|
|
|
queryInfo();
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (memcmp(code, kMsgCInfoAck, 4) == 0) {
|
|
|
|
infoAcknowledgment();
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (memcmp(code, kMsgDClipboard, 4) == 0) {
|
|
|
|
setClipboard();
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (memcmp(code, kMsgCResetOptions, 4) == 0) {
|
|
|
|
resetOptions();
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (memcmp(code, kMsgDSetOptions, 4) == 0) {
|
|
|
|
setOptions();
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (memcmp(code, kMsgCClose, 4) == 0) {
|
|
|
|
// server wants us to hangup
|
|
|
|
LOG((CLOG_DEBUG1 "recv close"));
|
|
|
|
m_client->disconnect(NULL);
|
|
|
|
return kDisconnect;
|
|
|
|
}
|
|
|
|
else if (memcmp(code, kMsgEBad, 4) == 0) {
|
|
|
|
LOG((CLOG_ERR "server disconnected due to a protocol error"));
|
|
|
|
m_client->disconnect("server reported a protocol error");
|
|
|
|
return kDisconnect;
|
|
|
|
}
|
|
|
|
else {
|
|
|
|
return kUnknown;
|
|
|
|
}
|
|
|
|
|
2004-11-06 16:29:06 +00:00
|
|
|
// send a reply. this is intended to work around a delay when
|
|
|
|
// running a linux server and an OS X (any BSD?) client. the
|
|
|
|
// client waits to send an ACK (if the system control flag
|
|
|
|
// net.inet.tcp.delayed_ack is 1) in hopes of piggybacking it
|
|
|
|
// on a data packet. we provide that packet here. i don't
|
|
|
|
// know why a delayed ACK should cause the server to wait since
|
|
|
|
// TCP_NODELAY is enabled.
|
|
|
|
CProtocolUtil::writef(m_stream, kMsgCNoop);
|
|
|
|
|
2004-02-28 12:19:49 +00:00
|
|
|
return kOkay;
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
2002-07-16 16:52:26 +00:00
|
|
|
void
|
2007-06-17 11:19:18 +00:00
|
|
|
CServerProxy::handleKeepAliveAlarm(const CEvent&, void*)
|
2002-07-16 16:52:26 +00:00
|
|
|
{
|
2007-06-17 11:19:18 +00:00
|
|
|
LOG((CLOG_NOTE "server is dead"));
|
|
|
|
m_client->disconnect("server is not responding");
|
2002-07-16 16:52:26 +00:00
|
|
|
}
|
|
|
|
|
2002-07-10 20:18:32 +00:00
|
|
|
void
|
2004-02-15 17:32:11 +00:00
|
|
|
CServerProxy::onInfoChanged()
|
2002-07-10 20:18:32 +00:00
|
|
|
{
|
|
|
|
// ignore mouse motion until we receive acknowledgment of our info
|
|
|
|
// change message.
|
|
|
|
m_ignoreMouse = true;
|
|
|
|
|
|
|
|
// send info update
|
2004-02-15 17:32:11 +00:00
|
|
|
queryInfo();
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
bool
|
2002-07-10 21:22:28 +00:00
|
|
|
CServerProxy::onGrabClipboard(ClipboardID id)
|
2002-07-10 20:18:32 +00:00
|
|
|
{
|
2002-10-15 21:29:44 +00:00
|
|
|
LOG((CLOG_DEBUG1 "sending clipboard %d changed", id));
|
2004-02-15 17:32:11 +00:00
|
|
|
CProtocolUtil::writef(m_stream, kMsgCClipboard, id, m_seqNum);
|
2002-07-11 13:13:37 +00:00
|
|
|
return true;
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
2004-02-15 17:32:11 +00:00
|
|
|
CServerProxy::onClipboardChanged(ClipboardID id, const IClipboard* clipboard)
|
2002-07-10 20:18:32 +00:00
|
|
|
{
|
2004-02-15 17:32:11 +00:00
|
|
|
CString data = IClipboard::marshall(clipboard);
|
2002-10-15 21:29:44 +00:00
|
|
|
LOG((CLOG_DEBUG1 "sending clipboard %d seqnum=%d, size=%d", id, m_seqNum, data.size()));
|
2004-02-15 17:32:11 +00:00
|
|
|
CProtocolUtil::writef(m_stream, kMsgDClipboard, id, m_seqNum, &data);
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
CServerProxy::flushCompressedMouse()
|
|
|
|
{
|
2004-02-15 17:32:11 +00:00
|
|
|
if (m_compressMouse) {
|
|
|
|
m_compressMouse = false;
|
|
|
|
m_client->mouseMove(m_xMouse, m_yMouse);
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
2004-05-02 08:03:49 +00:00
|
|
|
if (m_compressMouseRelative) {
|
|
|
|
m_compressMouseRelative = false;
|
|
|
|
m_client->mouseRelativeMove(m_dxMouse, m_dyMouse);
|
|
|
|
m_dxMouse = 0;
|
|
|
|
m_dyMouse = 0;
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
CServerProxy::sendInfo(const CClientInfo& info)
|
|
|
|
{
|
2004-02-15 17:32:11 +00:00
|
|
|
LOG((CLOG_DEBUG1 "sending info shape=%d,%d %dx%d", info.m_x, info.m_y, info.m_w, info.m_h));
|
|
|
|
CProtocolUtil::writef(m_stream, kMsgDInfo,
|
2002-07-10 20:18:32 +00:00
|
|
|
info.m_x, info.m_y,
|
2004-05-16 18:04:36 +00:00
|
|
|
info.m_w, info.m_h, 0,
|
|
|
|
info.m_mx, info.m_my);
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
2003-02-22 15:03:31 +00:00
|
|
|
KeyID
|
|
|
|
CServerProxy::translateKey(KeyID id) const
|
|
|
|
{
|
|
|
|
static const KeyID s_translationTable[kKeyModifierIDLast][2] = {
|
|
|
|
{ kKeyNone, kKeyNone },
|
|
|
|
{ kKeyShift_L, kKeyShift_R },
|
|
|
|
{ kKeyControl_L, kKeyControl_R },
|
|
|
|
{ kKeyAlt_L, kKeyAlt_R },
|
|
|
|
{ kKeyMeta_L, kKeyMeta_R },
|
|
|
|
{ kKeySuper_L, kKeySuper_R }
|
|
|
|
};
|
|
|
|
|
|
|
|
KeyModifierID id2 = kKeyModifierIDNull;
|
|
|
|
UInt32 side = 0;
|
|
|
|
switch (id) {
|
|
|
|
case kKeyShift_L:
|
|
|
|
id2 = kKeyModifierIDShift;
|
|
|
|
side = 0;
|
|
|
|
break;
|
|
|
|
|
|
|
|
case kKeyShift_R:
|
|
|
|
id2 = kKeyModifierIDShift;
|
|
|
|
side = 1;
|
|
|
|
break;
|
|
|
|
|
|
|
|
case kKeyControl_L:
|
|
|
|
id2 = kKeyModifierIDControl;
|
|
|
|
side = 0;
|
|
|
|
break;
|
|
|
|
|
|
|
|
case kKeyControl_R:
|
|
|
|
id2 = kKeyModifierIDControl;
|
|
|
|
side = 1;
|
|
|
|
break;
|
|
|
|
|
|
|
|
case kKeyAlt_L:
|
|
|
|
id2 = kKeyModifierIDAlt;
|
|
|
|
side = 0;
|
|
|
|
break;
|
|
|
|
|
|
|
|
case kKeyAlt_R:
|
|
|
|
id2 = kKeyModifierIDAlt;
|
|
|
|
side = 1;
|
|
|
|
break;
|
|
|
|
|
|
|
|
case kKeyMeta_L:
|
|
|
|
id2 = kKeyModifierIDMeta;
|
|
|
|
side = 0;
|
|
|
|
break;
|
|
|
|
|
|
|
|
case kKeyMeta_R:
|
|
|
|
id2 = kKeyModifierIDMeta;
|
|
|
|
side = 1;
|
|
|
|
break;
|
|
|
|
|
|
|
|
case kKeySuper_L:
|
|
|
|
id2 = kKeyModifierIDSuper;
|
|
|
|
side = 0;
|
|
|
|
break;
|
|
|
|
|
|
|
|
case kKeySuper_R:
|
|
|
|
id2 = kKeyModifierIDSuper;
|
|
|
|
side = 1;
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
|
|
|
|
if (id2 != kKeyModifierIDNull) {
|
|
|
|
return s_translationTable[m_modifierTranslationTable[id2]][side];
|
|
|
|
}
|
|
|
|
else {
|
|
|
|
return id;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
KeyModifierMask
|
|
|
|
CServerProxy::translateModifierMask(KeyModifierMask mask) const
|
|
|
|
{
|
|
|
|
static const KeyModifierMask s_masks[kKeyModifierIDLast] = {
|
|
|
|
0x0000,
|
|
|
|
KeyModifierShift,
|
|
|
|
KeyModifierControl,
|
|
|
|
KeyModifierAlt,
|
|
|
|
KeyModifierMeta,
|
|
|
|
KeyModifierSuper
|
|
|
|
};
|
|
|
|
|
2003-06-22 16:39:25 +00:00
|
|
|
KeyModifierMask newMask = mask & ~(KeyModifierShift |
|
|
|
|
KeyModifierControl |
|
|
|
|
KeyModifierAlt |
|
|
|
|
KeyModifierMeta |
|
|
|
|
KeyModifierSuper);
|
2003-02-22 15:03:31 +00:00
|
|
|
if ((mask & KeyModifierShift) != 0) {
|
|
|
|
newMask |= s_masks[m_modifierTranslationTable[kKeyModifierIDShift]];
|
|
|
|
}
|
|
|
|
if ((mask & KeyModifierControl) != 0) {
|
|
|
|
newMask |= s_masks[m_modifierTranslationTable[kKeyModifierIDControl]];
|
|
|
|
}
|
|
|
|
if ((mask & KeyModifierAlt) != 0) {
|
|
|
|
newMask |= s_masks[m_modifierTranslationTable[kKeyModifierIDAlt]];
|
|
|
|
}
|
|
|
|
if ((mask & KeyModifierMeta) != 0) {
|
|
|
|
newMask |= s_masks[m_modifierTranslationTable[kKeyModifierIDMeta]];
|
|
|
|
}
|
|
|
|
if ((mask & KeyModifierSuper) != 0) {
|
|
|
|
newMask |= s_masks[m_modifierTranslationTable[kKeyModifierIDSuper]];
|
|
|
|
}
|
2003-03-12 22:34:07 +00:00
|
|
|
return newMask;
|
2003-02-22 15:03:31 +00:00
|
|
|
}
|
|
|
|
|
2002-07-10 20:18:32 +00:00
|
|
|
void
|
|
|
|
CServerProxy::enter()
|
|
|
|
{
|
|
|
|
// parse
|
|
|
|
SInt16 x, y;
|
|
|
|
UInt16 mask;
|
|
|
|
UInt32 seqNum;
|
2004-02-15 17:32:11 +00:00
|
|
|
CProtocolUtil::readf(m_stream, kMsgCEnter + 4, &x, &y, &seqNum, &mask);
|
2002-10-15 21:29:44 +00:00
|
|
|
LOG((CLOG_DEBUG1 "recv enter, %d,%d %d %04x", x, y, seqNum, mask));
|
2002-07-10 20:18:32 +00:00
|
|
|
|
|
|
|
// discard old compressed mouse motion, if any
|
2004-05-02 08:03:49 +00:00
|
|
|
m_compressMouse = false;
|
|
|
|
m_compressMouseRelative = false;
|
|
|
|
m_dxMouse = 0;
|
|
|
|
m_dyMouse = 0;
|
|
|
|
m_seqNum = seqNum;
|
2002-07-10 20:18:32 +00:00
|
|
|
|
|
|
|
// forward
|
2004-02-15 17:32:11 +00:00
|
|
|
m_client->enter(x, y, seqNum, static_cast<KeyModifierMask>(mask), false);
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
CServerProxy::leave()
|
|
|
|
{
|
|
|
|
// parse
|
2002-10-15 21:29:44 +00:00
|
|
|
LOG((CLOG_DEBUG1 "recv leave"));
|
2002-07-10 20:18:32 +00:00
|
|
|
|
|
|
|
// send last mouse motion
|
|
|
|
flushCompressedMouse();
|
|
|
|
|
|
|
|
// forward
|
2004-02-15 17:32:11 +00:00
|
|
|
m_client->leave();
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
CServerProxy::setClipboard()
|
|
|
|
{
|
|
|
|
// parse
|
|
|
|
ClipboardID id;
|
|
|
|
UInt32 seqNum;
|
|
|
|
CString data;
|
2004-02-15 17:32:11 +00:00
|
|
|
CProtocolUtil::readf(m_stream, kMsgDClipboard + 4, &id, &seqNum, &data);
|
2002-10-15 21:29:44 +00:00
|
|
|
LOG((CLOG_DEBUG "recv clipboard %d size=%d", id, data.size()));
|
2002-07-10 20:18:32 +00:00
|
|
|
|
|
|
|
// validate
|
|
|
|
if (id >= kClipboardEnd) {
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
// forward
|
2004-02-15 17:32:11 +00:00
|
|
|
CClipboard clipboard;
|
|
|
|
clipboard.unmarshall(data, 0);
|
|
|
|
m_client->setClipboard(id, &clipboard);
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
CServerProxy::grabClipboard()
|
|
|
|
{
|
|
|
|
// parse
|
|
|
|
ClipboardID id;
|
|
|
|
UInt32 seqNum;
|
2004-02-15 17:32:11 +00:00
|
|
|
CProtocolUtil::readf(m_stream, kMsgCClipboard + 4, &id, &seqNum);
|
2002-10-15 21:29:44 +00:00
|
|
|
LOG((CLOG_DEBUG "recv grab clipboard %d", id));
|
2002-07-10 20:18:32 +00:00
|
|
|
|
|
|
|
// validate
|
|
|
|
if (id >= kClipboardEnd) {
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
// forward
|
2004-02-15 17:32:11 +00:00
|
|
|
m_client->grabClipboard(id);
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
CServerProxy::keyDown()
|
|
|
|
{
|
|
|
|
// get mouse up to date
|
|
|
|
flushCompressedMouse();
|
|
|
|
|
|
|
|
// parse
|
2003-04-27 17:01:14 +00:00
|
|
|
UInt16 id, mask, button;
|
2004-02-15 17:32:11 +00:00
|
|
|
CProtocolUtil::readf(m_stream, kMsgDKeyDown + 4, &id, &mask, &button);
|
2004-03-28 14:05:52 +00:00
|
|
|
LOG((CLOG_DEBUG1 "recv key down id=0x%08x, mask=0x%04x, button=0x%04x", id, mask, button));
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2003-02-22 15:03:31 +00:00
|
|
|
// translate
|
|
|
|
KeyID id2 = translateKey(static_cast<KeyID>(id));
|
|
|
|
KeyModifierMask mask2 = translateModifierMask(
|
2002-07-10 20:18:32 +00:00
|
|
|
static_cast<KeyModifierMask>(mask));
|
2003-02-22 15:03:31 +00:00
|
|
|
if (id2 != static_cast<KeyID>(id) ||
|
|
|
|
mask2 != static_cast<KeyModifierMask>(mask))
|
2004-03-28 14:05:52 +00:00
|
|
|
LOG((CLOG_DEBUG1 "key down translated to id=0x%08x, mask=0x%04x", id2, mask2));
|
2003-02-22 15:03:31 +00:00
|
|
|
|
|
|
|
// forward
|
2004-02-15 17:32:11 +00:00
|
|
|
m_client->keyDown(id2, mask2, button);
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
CServerProxy::keyRepeat()
|
|
|
|
{
|
|
|
|
// get mouse up to date
|
|
|
|
flushCompressedMouse();
|
|
|
|
|
|
|
|
// parse
|
2003-04-27 17:01:14 +00:00
|
|
|
UInt16 id, mask, count, button;
|
2004-02-15 17:32:11 +00:00
|
|
|
CProtocolUtil::readf(m_stream, kMsgDKeyRepeat + 4,
|
2003-04-27 17:01:14 +00:00
|
|
|
&id, &mask, &count, &button);
|
2004-03-28 14:05:52 +00:00
|
|
|
LOG((CLOG_DEBUG1 "recv key repeat id=0x%08x, mask=0x%04x, count=%d, button=0x%04x", id, mask, count, button));
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2003-02-22 15:03:31 +00:00
|
|
|
// translate
|
|
|
|
KeyID id2 = translateKey(static_cast<KeyID>(id));
|
|
|
|
KeyModifierMask mask2 = translateModifierMask(
|
|
|
|
static_cast<KeyModifierMask>(mask));
|
|
|
|
if (id2 != static_cast<KeyID>(id) ||
|
|
|
|
mask2 != static_cast<KeyModifierMask>(mask))
|
2004-03-28 14:05:52 +00:00
|
|
|
LOG((CLOG_DEBUG1 "key repeat translated to id=0x%08x, mask=0x%04x", id2, mask2));
|
2003-02-22 15:03:31 +00:00
|
|
|
|
2002-07-10 20:18:32 +00:00
|
|
|
// forward
|
2004-02-15 17:32:11 +00:00
|
|
|
m_client->keyRepeat(id2, mask2, count, button);
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
CServerProxy::keyUp()
|
|
|
|
{
|
|
|
|
// get mouse up to date
|
|
|
|
flushCompressedMouse();
|
|
|
|
|
|
|
|
// parse
|
2003-04-27 17:01:14 +00:00
|
|
|
UInt16 id, mask, button;
|
2004-02-15 17:32:11 +00:00
|
|
|
CProtocolUtil::readf(m_stream, kMsgDKeyUp + 4, &id, &mask, &button);
|
2004-03-28 14:05:52 +00:00
|
|
|
LOG((CLOG_DEBUG1 "recv key up id=0x%08x, mask=0x%04x, button=0x%04x", id, mask, button));
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2003-02-22 15:03:31 +00:00
|
|
|
// translate
|
|
|
|
KeyID id2 = translateKey(static_cast<KeyID>(id));
|
|
|
|
KeyModifierMask mask2 = translateModifierMask(
|
2002-07-10 20:18:32 +00:00
|
|
|
static_cast<KeyModifierMask>(mask));
|
2003-02-22 15:03:31 +00:00
|
|
|
if (id2 != static_cast<KeyID>(id) ||
|
|
|
|
mask2 != static_cast<KeyModifierMask>(mask))
|
2004-03-28 14:05:52 +00:00
|
|
|
LOG((CLOG_DEBUG1 "key up translated to id=0x%08x, mask=0x%04x", id2, mask2));
|
2003-02-22 15:03:31 +00:00
|
|
|
|
|
|
|
// forward
|
2004-02-15 17:32:11 +00:00
|
|
|
m_client->keyUp(id2, mask2, button);
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
CServerProxy::mouseDown()
|
|
|
|
{
|
|
|
|
// get mouse up to date
|
|
|
|
flushCompressedMouse();
|
|
|
|
|
|
|
|
// parse
|
|
|
|
SInt8 id;
|
2004-02-15 17:32:11 +00:00
|
|
|
CProtocolUtil::readf(m_stream, kMsgDMouseDown + 4, &id);
|
2002-10-15 21:29:44 +00:00
|
|
|
LOG((CLOG_DEBUG1 "recv mouse down id=%d", id));
|
2002-07-10 20:18:32 +00:00
|
|
|
|
|
|
|
// forward
|
2004-02-15 17:32:11 +00:00
|
|
|
m_client->mouseDown(static_cast<ButtonID>(id));
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
CServerProxy::mouseUp()
|
|
|
|
{
|
|
|
|
// get mouse up to date
|
|
|
|
flushCompressedMouse();
|
|
|
|
|
|
|
|
// parse
|
|
|
|
SInt8 id;
|
2004-02-15 17:32:11 +00:00
|
|
|
CProtocolUtil::readf(m_stream, kMsgDMouseUp + 4, &id);
|
2002-10-15 21:29:44 +00:00
|
|
|
LOG((CLOG_DEBUG1 "recv mouse up id=%d", id));
|
2002-07-10 20:18:32 +00:00
|
|
|
|
|
|
|
// forward
|
2004-02-15 17:32:11 +00:00
|
|
|
m_client->mouseUp(static_cast<ButtonID>(id));
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
CServerProxy::mouseMove()
|
|
|
|
{
|
|
|
|
// parse
|
|
|
|
bool ignore;
|
|
|
|
SInt16 x, y;
|
2004-02-15 17:32:11 +00:00
|
|
|
CProtocolUtil::readf(m_stream, kMsgDMouseMove + 4, &x, &y);
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-15 17:32:11 +00:00
|
|
|
// note if we should ignore the move
|
|
|
|
ignore = m_ignoreMouse;
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-15 17:32:11 +00:00
|
|
|
// compress mouse motion events if more input follows
|
|
|
|
if (!ignore && !m_compressMouse && m_stream->isReady()) {
|
|
|
|
m_compressMouse = true;
|
|
|
|
}
|
2002-07-10 20:18:32 +00:00
|
|
|
|
2004-02-15 17:32:11 +00:00
|
|
|
// if compressing then ignore the motion but record it
|
|
|
|
if (m_compressMouse) {
|
2004-05-02 08:03:49 +00:00
|
|
|
m_compressMouseRelative = false;
|
|
|
|
ignore = true;
|
|
|
|
m_xMouse = x;
|
|
|
|
m_yMouse = y;
|
|
|
|
m_dxMouse = 0;
|
|
|
|
m_dyMouse = 0;
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
2002-10-15 21:29:44 +00:00
|
|
|
LOG((CLOG_DEBUG2 "recv mouse move %d,%d", x, y));
|
2002-07-10 20:18:32 +00:00
|
|
|
|
|
|
|
// forward
|
|
|
|
if (!ignore) {
|
2004-02-15 17:32:11 +00:00
|
|
|
m_client->mouseMove(x, y);
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2004-05-02 08:03:49 +00:00
|
|
|
void
|
|
|
|
CServerProxy::mouseRelativeMove()
|
|
|
|
{
|
|
|
|
// parse
|
|
|
|
bool ignore;
|
|
|
|
SInt16 dx, dy;
|
|
|
|
CProtocolUtil::readf(m_stream, kMsgDMouseRelMove + 4, &dx, &dy);
|
|
|
|
|
|
|
|
// note if we should ignore the move
|
|
|
|
ignore = m_ignoreMouse;
|
|
|
|
|
|
|
|
// compress mouse motion events if more input follows
|
|
|
|
if (!ignore && !m_compressMouseRelative && m_stream->isReady()) {
|
|
|
|
m_compressMouseRelative = true;
|
|
|
|
}
|
|
|
|
|
|
|
|
// if compressing then ignore the motion but record it
|
|
|
|
if (m_compressMouseRelative) {
|
|
|
|
ignore = true;
|
|
|
|
m_dxMouse += dx;
|
|
|
|
m_dyMouse += dy;
|
|
|
|
}
|
|
|
|
LOG((CLOG_DEBUG2 "recv mouse relative move %d,%d", dx, dy));
|
|
|
|
|
|
|
|
// forward
|
|
|
|
if (!ignore) {
|
|
|
|
m_client->mouseRelativeMove(dx, dy);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2002-07-10 20:18:32 +00:00
|
|
|
void
|
|
|
|
CServerProxy::mouseWheel()
|
|
|
|
{
|
|
|
|
// get mouse up to date
|
|
|
|
flushCompressedMouse();
|
|
|
|
|
|
|
|
// parse
|
2007-06-17 11:19:18 +00:00
|
|
|
SInt16 xDelta, yDelta;
|
|
|
|
CProtocolUtil::readf(m_stream, kMsgDMouseWheel + 4, &xDelta, &yDelta);
|
|
|
|
LOG((CLOG_DEBUG2 "recv mouse wheel %+d,%+d", xDelta, yDelta));
|
2002-07-10 20:18:32 +00:00
|
|
|
|
|
|
|
// forward
|
2007-06-17 11:19:18 +00:00
|
|
|
m_client->mouseWheel(xDelta, yDelta);
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
2002-07-13 22:00:38 +00:00
|
|
|
CServerProxy::screensaver()
|
2002-07-10 20:18:32 +00:00
|
|
|
{
|
|
|
|
// parse
|
|
|
|
SInt8 on;
|
2004-02-15 17:32:11 +00:00
|
|
|
CProtocolUtil::readf(m_stream, kMsgCScreenSaver + 4, &on);
|
2002-10-15 21:29:44 +00:00
|
|
|
LOG((CLOG_DEBUG1 "recv screen saver on=%d", on));
|
2002-07-10 20:18:32 +00:00
|
|
|
|
|
|
|
// forward
|
2004-02-15 17:32:11 +00:00
|
|
|
m_client->screensaver(on != 0);
|
2002-07-10 20:18:32 +00:00
|
|
|
}
|
|
|
|
|
2002-12-23 14:47:44 +00:00
|
|
|
void
|
|
|
|
CServerProxy::resetOptions()
|
|
|
|
{
|
|
|
|
// parse
|
|
|
|
LOG((CLOG_DEBUG1 "recv reset options"));
|
|
|
|
|
|
|
|
// forward
|
2004-02-15 17:32:11 +00:00
|
|
|
m_client->resetOptions();
|
2003-02-22 15:03:31 +00:00
|
|
|
|
2007-06-17 11:19:18 +00:00
|
|
|
// reset keep alive
|
|
|
|
setKeepAliveRate(kKeepAliveRate);
|
2003-02-22 16:20:23 +00:00
|
|
|
|
2003-02-22 15:03:31 +00:00
|
|
|
// reset modifier translation table
|
2003-02-22 16:20:23 +00:00
|
|
|
for (KeyModifierID id = 0; id < kKeyModifierIDLast; ++id) {
|
2003-02-22 15:03:31 +00:00
|
|
|
m_modifierTranslationTable[id] = id;
|
2003-02-22 16:20:23 +00:00
|
|
|
}
|
2002-12-23 14:47:44 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
CServerProxy::setOptions()
|
|
|
|
{
|
|
|
|
// parse
|
|
|
|
COptionsList options;
|
2004-02-15 17:32:11 +00:00
|
|
|
CProtocolUtil::readf(m_stream, kMsgDSetOptions + 4, &options);
|
2002-12-23 14:47:44 +00:00
|
|
|
LOG((CLOG_DEBUG1 "recv set options size=%d", options.size()));
|
|
|
|
|
|
|
|
// forward
|
2004-02-15 17:32:11 +00:00
|
|
|
m_client->setOptions(options);
|
2003-02-22 16:20:23 +00:00
|
|
|
|
2003-02-22 15:03:31 +00:00
|
|
|
// update modifier table
|
|
|
|
for (UInt32 i = 0, n = options.size(); i < n; i += 2) {
|
|
|
|
KeyModifierID id = kKeyModifierIDNull;
|
|
|
|
if (options[i] == kOptionModifierMapForShift) {
|
|
|
|
id = kKeyModifierIDShift;
|
|
|
|
}
|
|
|
|
else if (options[i] == kOptionModifierMapForControl) {
|
|
|
|
id = kKeyModifierIDControl;
|
|
|
|
}
|
|
|
|
else if (options[i] == kOptionModifierMapForAlt) {
|
|
|
|
id = kKeyModifierIDAlt;
|
|
|
|
}
|
|
|
|
else if (options[i] == kOptionModifierMapForMeta) {
|
|
|
|
id = kKeyModifierIDMeta;
|
|
|
|
}
|
|
|
|
else if (options[i] == kOptionModifierMapForSuper) {
|
|
|
|
id = kKeyModifierIDSuper;
|
|
|
|
}
|
2003-02-22 16:20:23 +00:00
|
|
|
else if (options[i] == kOptionHeartbeat) {
|
2007-06-17 11:19:18 +00:00
|
|
|
// update keep alive
|
|
|
|
setKeepAliveRate(1.0e-3 * static_cast<double>(options[i + 1]));
|
2003-02-22 16:20:23 +00:00
|
|
|
}
|
2003-02-22 15:03:31 +00:00
|
|
|
if (id != kKeyModifierIDNull) {
|
|
|
|
m_modifierTranslationTable[id] =
|
|
|
|
static_cast<KeyModifierID>(options[i + 1]);
|
|
|
|
LOG((CLOG_DEBUG1 "modifier %d mapped to %d", id, m_modifierTranslationTable[id]));
|
|
|
|
}
|
|
|
|
}
|
2002-12-23 14:47:44 +00:00
|
|
|
}
|
|
|
|
|
2002-07-10 20:18:32 +00:00
|
|
|
void
|
|
|
|
CServerProxy::queryInfo()
|
|
|
|
{
|
|
|
|
CClientInfo info;
|
2004-02-15 17:32:11 +00:00
|
|
|
m_client->getShape(info.m_x, info.m_y, info.m_w, info.m_h);
|
2004-05-16 18:04:36 +00:00
|
|
|
m_client->getCursorPos(info.m_mx, info.m_my);
|
2002-07-10 20:18:32 +00:00
|
|
|
sendInfo(info);
|
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
CServerProxy::infoAcknowledgment()
|
|
|
|
{
|
2002-10-15 21:29:44 +00:00
|
|
|
LOG((CLOG_DEBUG1 "recv info acknowledgment"));
|
2002-07-10 20:18:32 +00:00
|
|
|
m_ignoreMouse = false;
|
|
|
|
}
|