Added support for a global relative mouse motion option. When true

and on a secondary screen and locked to the screen (via scroll lock)
mouse motion is sent as motion deltas.  When true and scroll lock
is toggled off the mouse is warped to the secondary screen's center
so the server knows where it is.  This option is intended to support
games and other programs that repeatedly warp the mouse to the center
of the screen.  This change adds general and X11 support but not
win32.  The option name is "relativeMouseMoves".
This commit is contained in:
crs
2004-05-01 15:18:59 +00:00
parent 320cc754a2
commit 16110acaa2
22 changed files with 138 additions and 12 deletions

View File

@@ -26,8 +26,6 @@
#include "stdset.h"
#include "stdvector.h"
class CClientProxy;
class CClientProxyUnknown;
class CEventQueueTimer;
class CPrimaryClient;
class IClient;
@@ -183,6 +181,9 @@ private:
// returns true iff the delay switch timer is started
bool isSwitchWaitStarted() const;
// stop relative mouse moves
void stopRelativeMoves();
// send screen options to \c client
void sendOptions(IClient* client) const;
@@ -312,6 +313,9 @@ private:
bool m_switchTwoTapArmed;
SInt32 m_switchTwoTapZone;
// relative mouse move option
bool m_relativeMoves;
static CEvent::Type s_errorEvent;
static CEvent::Type s_disconnectedEvent;
};