Mercurial > mm7
annotate Mouse.h @ 2473:98eda972505f
backing out of previous commit for Indoor.cpp
author | zipi |
---|---|
date | Tue, 19 Aug 2014 22:33:23 +0100 |
parents | 0313c761d203 |
children | 68cdef6879a0 |
rev | line source |
---|---|
0 | 1 #pragma once |
1802 | 2 #include "OSWindow.h" |
0 | 3 |
4 #include "VectorTypes.h" | |
5 | |
6 | |
7 | |
8 /* 107 */ | |
9 #pragma pack(push, 1) | |
1103 | 10 class ThreadWard |
0 | 11 { |
1103 | 12 public: |
0 | 13 //----- (00438B0B) -------------------------------------------------------- |
14 inline ThreadWard() | |
15 { | |
16 InitializeCriticalSection(&csAsyncMouse); | |
17 InitializeCriticalSection(&cs2); | |
18 InitializeCriticalSection(&cs3); | |
19 InitializeCriticalSection(&csAsyncKeyboard); | |
20 } | |
21 | |
22 //----- (00438B54) -------------------------------------------------------- | |
23 virtual ~ThreadWard() | |
24 { | |
25 ThreadWard *v1; // esi@1 | |
26 | |
27 v1 = this; | |
28 //this->vdestructor_ptr = &ThreadWard_destructors; | |
29 DeleteCriticalSection(&this->csAsyncKeyboard); | |
30 DeleteCriticalSection(&v1->cs3); | |
31 DeleteCriticalSection(&v1->cs2); | |
32 DeleteCriticalSection(&v1->csAsyncMouse); | |
33 } | |
34 | |
1458 | 35 void ( ***vdestructor_ptr)(ThreadWard *, bool); |
0 | 36 _RTL_CRITICAL_SECTION csAsyncMouse; |
37 _RTL_CRITICAL_SECTION cs2; | |
38 _RTL_CRITICAL_SECTION cs3; | |
39 _RTL_CRITICAL_SECTION csAsyncKeyboard; | |
40 }; | |
41 #pragma pack(pop) | |
42 | |
43 /* 106 */ | |
44 #pragma pack(push, 1) | |
1103 | 45 class Mouse |
0 | 46 { |
1103 | 47 public: |
0 | 48 //----- (00467E4E) -------------------------------------------------------- |
1802 | 49 inline Mouse(): |
50 window(nullptr) | |
0 | 51 { |
52 uCursorTextureID = 0; | |
53 uCursorTextureID_2 = 0; | |
2369
bddcaf5d5db2
removing non-nullptr conditions before frees, chaning 0 and NULL assignmnets to pointers to nullptr assignments
Grumpy7
parents:
2339
diff
changeset
|
54 pCursorBitmap_sysmem = nullptr; |
0 | 55 field_34 = 0; |
2369
bddcaf5d5db2
removing non-nullptr conditions before frees, chaning 0 and NULL assignmnets to pointers to nullptr assignments
Grumpy7
parents:
2339
diff
changeset
|
56 pCursorBitmap2_sysmem = nullptr; |
bddcaf5d5db2
removing non-nullptr conditions before frees, chaning 0 and NULL assignmnets to pointers to nullptr assignments
Grumpy7
parents:
2339
diff
changeset
|
57 pCursorBitmap3_sysmembits_16bit = nullptr; |
bddcaf5d5db2
removing non-nullptr conditions before frees, chaning 0 and NULL assignmnets to pointers to nullptr assignments
Grumpy7
parents:
2339
diff
changeset
|
58 ptr_90 = nullptr; |
2420 | 59 pWard = nullptr; |
60 *pCurrentCursorName = NULL; | |
61 uMouseClickX = 0; | |
62 uMouseClickY = 0; | |
0 | 63 } |
64 | |
65 void GetClickPos(unsigned int *pX, unsigned int *pY); | |
66 void RemoveHoldingItem(); | |
67 void SetCursorBitmapFromItemID(unsigned int uItemID); | |
68 void SetCurrentCursorBitmap(); | |
69 void SetCursorBitmap(const char *pName); | |
70 LONG _469AE4(); | |
71 void ClearCursor(); | |
72 void AllocCursorSystemMem(); | |
73 void *DoAllocCursorMem(); | |
74 POINT *GetCursorPos(POINT *p); | |
1802 | 75 void Initialize(OSWindow *window); |
762 | 76 void SetActive(bool active); |
0 | 77 void Deactivate(); |
78 void DrawCursor(); | |
2216 | 79 void Activate(); |
0 | 80 void _469E24(); |
81 void DrawCursorToTarget(); | |
2216 | 82 void ReadCursorWithItem(); |
83 void ChangeActivation(int a1); | |
0 | 84 void SetMouseClick(int x, int y); |
85 | |
2339 | 86 static void UI_OnMouseLeftClick(int *pXY); // idb |
87 static bool UI_OnKeyDown(unsigned int vkKey); | |
88 | |
0 | 89 |
90 unsigned int uPointingObjectID; | |
91 unsigned int bActive; | |
92 int field_8; | |
93 int field_C; | |
94 unsigned int bInitialized; | |
791 | 95 unsigned int bRedraw; |
0 | 96 int field_18; |
97 int field_1C; | |
98 int field_20; | |
99 unsigned int uCursorTextureID; | |
100 unsigned int uCursorTextureID_2; | |
1802 | 101 //HWND hWnd; |
102 OSWindow *window; | |
0 | 103 unsigned __int16 *pCursorBitmap_sysmem; |
104 int field_34; | |
105 unsigned __int8 *pCursorBitmap2_sysmem; | |
106 unsigned __int16 *pCursorBitmap3_sysmembits_16bit; | |
2216 | 107 int uCursorWithItemX; |
108 int uCursorWithItemY; | |
109 int uCursorWithItemW; | |
110 int uCursorWithItemZ; | |
0 | 111 int field_50; |
112 int field_54; | |
113 int uCursorBitmapPitch; | |
114 int field_5C[13]; | |
115 void *ptr_90; | |
116 int field_94; | |
117 int field_98; | |
118 int field_9C; | |
119 int field_A0; | |
120 int field_A4; | |
121 int field_A8; | |
122 int field_AC; | |
123 int field_B0; | |
124 int field_B4; | |
125 int field_B8; | |
126 int field_BC; | |
127 int field_C0; | |
128 Vec2_int_ pCursorBitmapPos; | |
129 int uCursorBitmapWidth; | |
130 int uCursorBitmapHeight; | |
131 int field_D4; | |
132 int field_D8; | |
133 int field_DC; | |
134 int field_E0; | |
135 Vec4_int_ pCursorBitmapRect; | |
136 char field_F4; | |
137 char pCurrentCursorName[11]; | |
138 int field_100; | |
139 int field_104; | |
140 unsigned int uMouseClickX; | |
141 unsigned int uMouseClickY; | |
1397 | 142 void/*ThreadWard*/ *pWard; |
0 | 143 }; |
144 #pragma pack(pop) | |
145 | |
146 | |
147 | |
148 | |
149 | |
1038 | 150 extern Mouse *pMouse; |