Deskflow 1.22.0.197
Keyboard and mouse sharing utility
Loading...
Searching...
No Matches
BaseClientProxy Class Referenceabstract

Generic proxy for client or primary. More...

#include <BaseClientProxy.h>

Inheritance diagram for BaseClientProxy:
Collaboration diagram for BaseClientProxy:

Public Member Functions

 BaseClientProxy (const std::string &name)
 ~BaseClientProxy () override=default
manipulators
void setJumpCursorPos (int32_t x, int32_t y)
 Save cursor position.
Public Member Functions inherited from IClient
Public Member Functions inherited from IScreen
Public Member Functions inherited from IInterface
virtual ~IInterface ()=default
 Interface destructor does nothing.

accessors

void getJumpCursorPos (int32_t &x, int32_t &y) const
 Get cursor position.
virtual bool isPrimary () const
 Get cursor position.
void * getEventTarget () const override=0
 Get event target.
bool getClipboard (ClipboardID id, IClipboard *) const override=0
 Get clipboard.
void getShape (int32_t &x, int32_t &y, int32_t &width, int32_t &height) const override=0
 Get screen shape.
void getCursorPos (int32_t &x, int32_t &y) const override=0
 Get cursor position.
void enter (int32_t xAbs, int32_t yAbs, uint32_t seqNum, KeyModifierMask mask, bool forScreensaver) override=0
 Enter screen.
bool leave () override=0
 Leave screen.
void setClipboard (ClipboardID, const IClipboard *) override=0
 Set clipboard.
void grabClipboard (ClipboardID) override=0
 Grab clipboard.
void setClipboardDirty (ClipboardID, bool) override=0
 Mark clipboard dirty.
void keyDown (KeyID, KeyModifierMask, KeyButton, const std::string &) override=0
 Notify of key press.
void keyRepeat (KeyID, KeyModifierMask, int32_t count, KeyButton, const std::string &lang) override=0
 Notify of key repeat.
void keyUp (KeyID, KeyModifierMask, KeyButton) override=0
 Notify of key release.
void mouseDown (ButtonID) override=0
 Notify of mouse press.
void mouseUp (ButtonID) override=0
 Notify of mouse release.
void mouseMove (int32_t xAbs, int32_t yAbs) override=0
 Notify of mouse motion.
void mouseRelativeMove (int32_t xRel, int32_t yRel) override=0
 Notify of mouse motion.
void mouseWheel (int32_t xDelta, int32_t yDelta) override=0
 Notify of mouse wheel motion.
void screensaver (bool activate) override=0
 Notify of screen saver change.
void resetOptions () override=0
 Notify of options changes.
void setOptions (const OptionsList &options) override=0
 Notify of options changes.
virtual void sendDragInfo (uint32_t fileCount, const char *info, size_t size)=0
virtual void fileChunkSending (uint8_t mark, char *data, size_t dataSize)=0
virtual std::string getSecureInputApp () const =0
virtual void secureInputNotification (const std::string &app) const =0
std::string getName () const override
 Get client name.
virtual deskflow::IStreamgetStream () const =0

Detailed Description

Generic proxy for client or primary.

Constructor & Destructor Documentation

◆ BaseClientProxy()

BaseClientProxy::BaseClientProxy ( const std::string & name)
explicit

name is the name of the client.

◆ ~BaseClientProxy()

BaseClientProxy::~BaseClientProxy ( )
overridedefault

Member Function Documentation

◆ enter()

void BaseClientProxy::enter ( int32_t xAbs,
int32_t yAbs,
uint32_t seqNum,
KeyModifierMask mask,
bool forScreensaver )
overridepure virtual

Enter screen.

Enter the screen. The cursor should be warped to xAbs,yAbs. mask is the expected toggle button state and the client should update its state to match. forScreensaver is true iff the screen is being entered because the screen saver is starting. Subsequent clipboard events should report seqNum.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy, and PrimaryClient.

◆ fileChunkSending()

virtual void BaseClientProxy::fileChunkSending ( uint8_t mark,
char * data,
size_t dataSize )
pure virtual

◆ getClipboard()

bool BaseClientProxy::getClipboard ( ClipboardID id,
IClipboard *  ) const
overridepure virtual

Get clipboard.

Save the contents of the clipboard indicated by id and return true iff successful.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy, and PrimaryClient.

◆ getCursorPos()

void BaseClientProxy::getCursorPos ( int32_t & x,
int32_t & y ) const
overridepure virtual

Get cursor position.

Return the current position of the cursor in x and y.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy, and PrimaryClient.

◆ getEventTarget()

void * BaseClientProxy::getEventTarget ( ) const
overridepure virtual

Get event target.

Returns the target used for events created by this object.

Implements IClient.

Implemented in ClientProxy, and PrimaryClient.

◆ getJumpCursorPos()

void BaseClientProxy::getJumpCursorPos ( int32_t & x,
int32_t & y ) const

Get cursor position.

Get the position of the cursor when last jumping from client.

◆ getName()

std::string BaseClientProxy::getName ( ) const
overridevirtual

Get client name.

Return the client's name.

Implements IClient.

◆ getSecureInputApp()

virtual std::string BaseClientProxy::getSecureInputApp ( ) const
pure virtual

Implemented in ClientProxy1_0, and PrimaryClient.

◆ getShape()

void BaseClientProxy::getShape ( int32_t & x,
int32_t & y,
int32_t & width,
int32_t & height ) const
overridepure virtual

Get screen shape.

Return the position of the upper-left corner of the screen in x and y and the size of the screen in width and height.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy, and PrimaryClient.

◆ getStream()

virtual deskflow::IStream * BaseClientProxy::getStream ( ) const
pure virtual

Implemented in ClientProxy, and PrimaryClient.

◆ grabClipboard()

void BaseClientProxy::grabClipboard ( ClipboardID )
overridepure virtual

Grab clipboard.

Grab (i.e. take ownership of) the client's clipboard. Since this is called when another client takes ownership of the clipboard it implies that the client's clipboard is out of date.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy, and PrimaryClient.

◆ isPrimary()

virtual bool BaseClientProxy::isPrimary ( ) const
inlinevirtual

Get cursor position.

Return if this proxy is for client or primary.

Reimplemented in PrimaryClient.

◆ keyDown()

void BaseClientProxy::keyDown ( KeyID id,
KeyModifierMask ,
KeyButton ,
const std::string &  )
overridepure virtual

Notify of key press.

Synthesize key events to generate a press of key id. If possible match the given modifier mask. The KeyButton identifies the physical key on the server that generated this key down. The client must ensure that a key up or key repeat that uses the same KeyButton will synthesize an up or repeat for the same client key synthesized by keyDown().

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy1_1, ClientProxy1_4, ClientProxy1_8, ClientProxy, and PrimaryClient.

◆ keyRepeat()

void BaseClientProxy::keyRepeat ( KeyID id,
KeyModifierMask ,
int32_t count,
KeyButton ,
const std::string & lang )
overridepure virtual

Notify of key repeat.

Synthesize key events to generate a press and release of key id count times. If possible match the given modifier mask.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy1_1, ClientProxy1_4, ClientProxy, and PrimaryClient.

◆ keyUp()

void BaseClientProxy::keyUp ( KeyID id,
KeyModifierMask ,
KeyButton  )
overridepure virtual

Notify of key release.

Synthesize key events to generate a release of key id. If possible match the given modifier mask.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy1_1, ClientProxy1_4, ClientProxy, and PrimaryClient.

◆ leave()

bool BaseClientProxy::leave ( )
overridepure virtual

Leave screen.

Leave the screen. Return false iff the user may not leave the client's screen (because, for example, a button is down).

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy, and PrimaryClient.

◆ mouseDown()

void BaseClientProxy::mouseDown ( ButtonID id)
overridepure virtual

Notify of mouse press.

Synthesize mouse events to generate a press of mouse button id.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy, and PrimaryClient.

◆ mouseMove()

void BaseClientProxy::mouseMove ( int32_t xAbs,
int32_t yAbs )
overridepure virtual

Notify of mouse motion.

Synthesize mouse events to generate mouse motion to the absolute screen position xAbs,yAbs.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy, and PrimaryClient.

◆ mouseRelativeMove()

void BaseClientProxy::mouseRelativeMove ( int32_t xRel,
int32_t yRel )
overridepure virtual

Notify of mouse motion.

Synthesize mouse events to generate mouse motion by the relative amount xRel,yRel.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy1_2, ClientProxy, and PrimaryClient.

◆ mouseUp()

void BaseClientProxy::mouseUp ( ButtonID id)
overridepure virtual

Notify of mouse release.

Synthesize mouse events to generate a release of mouse button id.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy, and PrimaryClient.

◆ mouseWheel()

void BaseClientProxy::mouseWheel ( int32_t xDelta,
int32_t yDelta )
overridepure virtual

Notify of mouse wheel motion.

Synthesize mouse events to generate mouse wheel motion of xDelta and yDelta. Deltas are positive for motion away from the user or to the right and negative for motion towards the user or to the left. Each wheel click should generate a delta of +/-120.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy1_3, ClientProxy, and PrimaryClient.

◆ resetOptions()

void BaseClientProxy::resetOptions ( )
overridepure virtual

Notify of options changes.

Reset all options to their default values.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy, and PrimaryClient.

◆ screensaver()

void BaseClientProxy::screensaver ( bool activate)
overridepure virtual

Notify of screen saver change.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy, and PrimaryClient.

◆ secureInputNotification()

virtual void BaseClientProxy::secureInputNotification ( const std::string & app) const
pure virtual

◆ sendDragInfo()

virtual void BaseClientProxy::sendDragInfo ( uint32_t fileCount,
const char * info,
size_t size )
pure virtual

◆ setClipboard()

void BaseClientProxy::setClipboard ( ClipboardID ,
const IClipboard *  )
overridepure virtual

Set clipboard.

Update the client's clipboard. This implies that the client's clipboard is now up to date. If the client's clipboard was already known to be up to date then this may do nothing. data has marshalled clipboard data.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy1_6, ClientProxy, and PrimaryClient.

◆ setClipboardDirty()

void BaseClientProxy::setClipboardDirty ( ClipboardID ,
bool dirty )
overridepure virtual

Mark clipboard dirty.

Mark the client's clipboard as dirty (out of date) or clean (up to date).

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy, and PrimaryClient.

◆ setJumpCursorPos()

void BaseClientProxy::setJumpCursorPos ( int32_t x,
int32_t y )

Save cursor position.

Save the position of the cursor when jumping from client.

◆ setOptions()

void BaseClientProxy::setOptions ( const OptionsList & options)
overridepure virtual

Notify of options changes.

Set options to given values. Ignore unknown options and don't modify our options that aren't given in options.

Implements IClient.

Implemented in ClientProxy1_0, ClientProxy, and PrimaryClient.


The documentation for this class was generated from the following files: