Rabbit Remote Control 0.0.30
Loading...
Searching...
No Matches
CursorFreeRDP.h
1// Author: Kang Lin <kl222@126.com>
2
3#ifndef CCURSOR_H
4#define CCURSOR_H
5
6#include <QLoggingCategory>
7#include <QImage>
8#include <QRect>
9#include <QObject>
10#include "freerdp/freerdp.h"
11
12class CConnectFreeRDP;
13class CCursorFreeRDP : public QObject
14{
15 Q_OBJECT
16public:
17 explicit CCursorFreeRDP(CConnectFreeRDP *parent = nullptr);
18
19 int RegisterPointer(rdpGraphics* graphics);
20 struct _Pointer{
21 rdpPointer pointer;
22 CCursorFreeRDP* pThis;
23 };
24
25 static BOOL cb_Pointer_New(rdpContext* context, rdpPointer* pointer);
26 static void cb_Pointer_Free(rdpContext* context, rdpPointer* pointer);
27 static BOOL cb_Pointer_Set(rdpContext* context,
28 #if FreeRDP_VERSION_MAJOR >= 3
29 rdpPointer* pointer
30 #else
31 const rdpPointer* pointer
32 #endif
33 );
34 static BOOL cb_Pointer_SetNull(rdpContext* context);
35 static BOOL cb_Pointer_SetDefault(rdpContext* context);
36 static BOOL cb_Pointer_SetPosition(rdpContext* context, UINT32 x, UINT32 y);
37
38 BOOL onNew(rdpContext* context, rdpPointer* pointer);
39 void onFree(rdpContext* context, rdpPointer* pointer);
40 BOOL onSet(rdpContext* context, const rdpPointer* pointer);
41 BOOL onSetNull(rdpContext* context);
42 BOOL onSetDefault(rdpContext* context);
43 BOOL onSetPosition(rdpContext* context, UINT32 x, UINT32 y);
44
45private:
46 CConnectFreeRDP* m_pConnect;
47
48 QImage m_Cursor;
49 QLoggingCategory m_Logger;
50};
51
52#endif // CCURSOR_H
BOOL onNew(rdpContext *context, rdpPointer *pointer)
BOOL onSet(rdpContext *context, const rdpPointer *pointer)