#include <umsproto.hpp>
Public Types | |
| enum | RequestType { MOUSE_CTRL = 1, SEND_EVENT = 2, SEND_MESSAGE = 3, OPEN_WIN = 5, CLOSE_WIN = 6, OPEN_CNX = 7, CLOSE_CNX = 8 } |
| enum | Stat { Error = -1, CloseCnx = 0, Ok = 1, KeepCnx = 2 } |
Public Member Functions | |
| UMSrequest (unsigned char reqtype) | |
| int | size () |
| returns the size of the request (which is always a multiple of 8). | |
| void | readEvent (unsigned char &event_type, unsigned char &event_flow, long &x, long &y, unsigned long &detail) |
| void | writeEvent (unsigned char event_type, unsigned char event_flow, long x, long y, unsigned long detail) |
| char | readChar () |
| void | writeChar (char) |
| short | readShort () |
| void | writeShort (short) |
| long | readLong () |
| void | writeLong (long) |
| bool | writeString (const char *) |
| char * | getString () |
| NB: writeString() or getString must be the last call (only one string). | |
Public Attributes | |
| unsigned char | data [8 *256] |
| data sent to the UMS | |
| int | count |
| char count | |
size reqtype
(octal) (u_char) (c = u_char / c* = char* / l = long)
----------------------------------------------------------------------
s MOUSE_CTRL (c)evtype (c)evflow (l)x (l)y (l)btn|key|mvm
s SEND_EVENT (c)evtype (c)evflow (l)x (l)y (l)btn|key|mvm (c*)target...
s SEND_MESSAGE (c*)target... (c*)message...
s OPEN_WIN (l)win_no
s CLOSE_WIN (l)win_no
s OPEN_CNX (c*)apname...
s CLOSE_CNX (c*)apname...
----------------------------------------------------------------------
target can be:
winid[:evflow] with winid = ascii-name-without-blanks or quoted 'asci name'
or decimal (1234) or hexa number (0x1234a)
#win:/[display]/winid[:evflow] (display is opt and ... never used)
#ptr:/[display]/ptrid[:evflow] with ptrid = 0, 1 ... (useless)
|
|
char count this variable is used by the write*() and read*() functions to store or retreive the data (but it is not sent to the UMS, the size/8 being eventually stored in data[0] |
|
|
data sent to the UMS Notes:
|
1.4.1