ReactOS  0.4.14-dev-815-ge410a12
accel.c File Reference
#include <user32.h>
Include dependency graph for accel.c:

Go to the source code of this file.

Classes

struct  PE_ACCEL
 
struct  _USER_ACCEL_CACHE_ENTRY
 

Typedefs

typedef struct PE_ACCELLPPE_ACCEL
 
typedef struct _USER_ACCEL_CACHE_ENTRY U32_ACCEL_CACHE_ENTRY
 

Functions

U32_ACCEL_CACHE_ENTRY **WINAPI U32AccelCacheFind (HANDLE Object, HGLOBAL Data)
 
void WINAPI U32AccelCacheAdd (HACCEL Object, HGLOBAL Data)
 
HACCEL WINAPI U32LoadAccelerators (HINSTANCE hInstance, HRSRC hTableRes)
 
BOOL WINAPI U32IsValidAccelMessage (UINT uMsg)
 
BOOL WINAPI DestroyAcceleratorTable (HACCEL hAccel)
 
HACCEL WINAPI LoadAcceleratorsW (HINSTANCE hInstance, LPCWSTR lpTableName)
 
HACCEL WINAPI LoadAcceleratorsA (HINSTANCE hInstance, LPCSTR lpTableName)
 
int WINAPI TranslateAcceleratorW (HWND hWnd, HACCEL hAccTable, LPMSG lpMsg)
 
int WINAPI CopyAcceleratorTableA (HACCEL hAccelSrc, LPACCEL lpAccelDst, int cAccelEntries)
 
HACCEL WINAPI CreateAcceleratorTableA (LPACCEL lpaccl, int cEntries)
 
int WINAPI TranslateAcceleratorA (HWND hWnd, HACCEL hAccTable, LPMSG lpMsg)
 

Variables

CRITICAL_SECTION U32AccelCacheLock
 
U32_ACCEL_CACHE_ENTRYU32AccelCache = NULL
 

Typedef Documentation

◆ LPPE_ACCEL

◆ U32_ACCEL_CACHE_ENTRY

Function Documentation

◆ CopyAcceleratorTableA()

int WINAPI CopyAcceleratorTableA ( HACCEL  hAccelSrc,
LPACCEL  lpAccelDst,
int  cAccelEntries 
)

Definition at line 280 of file accel.c.

285 {
286  int i;
287 
288  cAccelEntries = CopyAcceleratorTableW(hAccelSrc, lpAccelDst, cAccelEntries);
289 
290  if (lpAccelDst == NULL) return cAccelEntries;
291 
292  for(i = 0; i < cAccelEntries; ++ i)
293  if(!(lpAccelDst[i].fVirt & FVIRTKEY))
294  {
295  NTSTATUS nErrCode = RtlUnicodeToMultiByteN(
296  (PCHAR)&lpAccelDst[i].key,
297  sizeof(lpAccelDst[i].key),
298  NULL,
299  (PWCHAR)&lpAccelDst[i].key,
300  sizeof(lpAccelDst[i].key)
301  );
302 
303  if(!NT_SUCCESS(nErrCode)) lpAccelDst[i].key = 0;
304  }
305 
306  return cAccelEntries;
307 }
signed char * PCHAR
Definition: retypes.h:7
LONG NTSTATUS
Definition: precomp.h:26
uint16_t * PWCHAR
Definition: typedefs.h:54
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
smooth NULL
Definition: ftsmooth.c:416
int WINAPI CopyAcceleratorTableW(_In_ HACCEL hAccelSrc, _Out_writes_to_opt_(cAccelEntries, return) LPACCEL lpAccelDst, _In_ int cAccelEntries)
WORD key
Definition: winuser.h:2899
#define NT_SUCCESS(StatCode)
Definition: apphelp.c:32
NTSYSAPI NTSTATUS NTAPI RtlUnicodeToMultiByteN(PCHAR MbString, ULONG MbSize, PULONG ResultSize, PCWCH UnicodeString, ULONG UnicodeSize)
#define FVIRTKEY
Definition: winuser.h:24
Definition: path.c:41

◆ CreateAcceleratorTableA()

HACCEL WINAPI CreateAcceleratorTableA ( LPACCEL  lpaccl,
int  cEntries 
)

Definition at line 313 of file accel.c.

314 {
315  int i;
316 
317  if (!cEntries || !lpaccl) return (HACCEL)0;
318 
319  for(i = 0; i < cEntries; ++ i)
320  if(!lpaccl[i].fVirt)
321  {
323  (
324  (PWCHAR)&lpaccl[i].key,
325  sizeof(lpaccl[i].key),
326  NULL,
327  (PCHAR)&lpaccl[i].key,
328  sizeof(lpaccl[i].key)
329  );
330 
331  if(!NT_SUCCESS(nErrCode)) lpaccl[i].key = -1;
332  }
333 
334  return CreateAcceleratorTableW(lpaccl, cEntries);
335 }
signed char * PCHAR
Definition: retypes.h:7
HACCEL WINAPI CreateAcceleratorTableW(_In_reads_(cAccel) LPACCEL paccel, _In_ int cAccel)
NTSYSAPI NTSTATUS WINAPI RtlMultiByteToUnicodeN(LPWSTR, DWORD, LPDWORD, LPCSTR, DWORD)
LONG NTSTATUS
Definition: precomp.h:26
uint16_t * PWCHAR
Definition: typedefs.h:54
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
smooth NULL
Definition: ftsmooth.c:416
WORD key
Definition: winuser.h:2899
#define NT_SUCCESS(StatCode)
Definition: apphelp.c:32
_In_ UINT _In_ UINT cEntries
Definition: wingdi.h:3619
Definition: path.c:41

◆ DestroyAcceleratorTable()

BOOL WINAPI DestroyAcceleratorTable ( HACCEL  hAccel)

Definition at line 191 of file accel.c.

192 {
193  U32_ACCEL_CACHE_ENTRY ** ppEntry;
194  ULONG_PTR nUsage = 0;
195 
196  if (!hAccel)
197  return FALSE;
198 
200 
201  /* see if this accelerator table has been cached */
202  ppEntry = U32AccelCacheFind(hAccel, NULL);
203 
204  /* accelerator table cached */
205  if(*ppEntry)
206  {
207  U32_ACCEL_CACHE_ENTRY * pEntry = *ppEntry;
208 
209  /* decrement the reference count */
210  nUsage = pEntry->Usage = pEntry->Usage - 1;
211 
212  /* reference count now zero: destroy the cache entry */
213  if(nUsage == 0)
214  {
215  /* unlink the cache entry */
216  *ppEntry = pEntry->Next;
217 
218  /* free the cache entry */
219  LocalFree(pEntry);
220  }
221  }
222 
224 
225  if(nUsage > 0) return FALSE;
226 
227  /* destroy the object */
229 }
U32_ACCEL_CACHE_ENTRY **WINAPI U32AccelCacheFind(HANDLE Object, HGLOBAL Data)
Definition: accel.c:60
struct _USER_ACCEL_CACHE_ENTRY * Next
Definition: accel.c:44
void WINAPI EnterCriticalSection(LPCRITICAL_SECTION)
uint32_t ULONG_PTR
Definition: typedefs.h:63
HACCEL hAccel
Definition: main.c:47
smooth NULL
Definition: ftsmooth.c:416
BOOLEAN NTAPI NtUserDestroyAcceleratorTable(HACCEL Table)
Definition: accelerator.c:344
HLOCAL NTAPI LocalFree(HLOCAL hMem)
Definition: heapmem.c:1577
ULONG_PTR Usage
Definition: accel.c:45
CRITICAL_SECTION U32AccelCacheLock
Definition: accel.c:54
void WINAPI LeaveCriticalSection(LPCRITICAL_SECTION)
Definition: accel.c:42

◆ LoadAcceleratorsA()

HACCEL WINAPI LoadAcceleratorsA ( HINSTANCE  hInstance,
LPCSTR  lpTableName 
)

Definition at line 250 of file accel.c.

251 {
252  HRSRC Accel;
253 
254  Accel = FindResourceExA(hInstance, (LPCSTR) RT_ACCELERATOR, lpTableName, 0);
255  if (NULL == Accel)
256  {
257  return NULL;
258  }
259 
260  return U32LoadAccelerators(hInstance, Accel);
261 }
HACCEL WINAPI U32LoadAccelerators(HINSTANCE hInstance, HRSRC hTableRes)
Definition: accel.c:94
HINSTANCE hInstance
Definition: charmap.c:20
smooth NULL
Definition: ftsmooth.c:416
HRSRC WINAPI FindResourceExA(HMODULE hModule, LPCSTR type, LPCSTR name, WORD lang)
Definition: res.c:143
const char * LPCSTR
Definition: xmlstorage.h:183
#define RT_ACCELERATOR
Definition: winuser.h:606

◆ LoadAcceleratorsW()

HACCEL WINAPI LoadAcceleratorsW ( HINSTANCE  hInstance,
LPCWSTR  lpTableName 
)

Definition at line 237 of file accel.c.

238 {
239  return U32LoadAccelerators
240  (
241  hInstance,
242  FindResourceExW(hInstance, (LPCWSTR) RT_ACCELERATOR, lpTableName, 0)
243  );
244 }
HACCEL WINAPI U32LoadAccelerators(HINSTANCE hInstance, HRSRC hTableRes)
Definition: accel.c:94
const WCHAR * LPCWSTR
Definition: xmlstorage.h:185
HINSTANCE hInstance
Definition: charmap.c:20
HRSRC WINAPI FindResourceExW(HMODULE hModule, LPCWSTR type, LPCWSTR name, WORD lang)
Definition: res.c:164
#define RT_ACCELERATOR
Definition: winuser.h:606

◆ TranslateAcceleratorA()

int WINAPI TranslateAcceleratorA ( HWND  hWnd,
HACCEL  hAccTable,
LPMSG  lpMsg 
)

Definition at line 341 of file accel.c.

342 {
343  switch (lpMsg->message)
344  {
345  case WM_KEYDOWN:
346  case WM_SYSKEYDOWN:
347  return TranslateAcceleratorW( hWnd, hAccTable, lpMsg );
348 
349  case WM_CHAR:
350  case WM_SYSCHAR:
351  {
352  MSG msgW = *lpMsg;
353  char ch = LOWORD(lpMsg->wParam);
354  WCHAR wch;
355  MultiByteToWideChar(CP_ACP, 0, &ch, 1, &wch, 1);
356  msgW.wParam = MAKEWPARAM(wch, HIWORD(lpMsg->wParam));
357  return TranslateAcceleratorW( hWnd, hAccTable, &msgW );
358  }
359 
360  default:
361  return 0;
362  }
363 }
#define MAKEWPARAM(l, h)
Definition: winuser.h:3984
#define WM_CHAR
Definition: winuser.h:1699
#define CP_ACP
Definition: compat.h:99
TW_UINT32 TW_UINT16 TW_UINT16 MSG
Definition: twain.h:1827
HWND hWnd
Definition: settings.c:17
WPARAM wParam
Definition: winuser.h:3091
#define WM_SYSCHAR
Definition: winuser.h:1703
#define WM_KEYDOWN
Definition: winuser.h:1697
__wchar_t WCHAR
Definition: xmlstorage.h:180
int WINAPI TranslateAcceleratorW(HWND hWnd, HACCEL hAccTable, LPMSG lpMsg)
Definition: accel.c:268
#define MultiByteToWideChar
Definition: compat.h:100
#define WM_SYSKEYDOWN
Definition: winuser.h:1701
#define HIWORD(l)
Definition: typedefs.h:246
UINT message
Definition: winuser.h:3090
#define LOWORD(l)
Definition: pedump.c:82

◆ TranslateAcceleratorW()

int WINAPI TranslateAcceleratorW ( HWND  hWnd,
HACCEL  hAccTable,
LPMSG  lpMsg 
)

Definition at line 268 of file accel.c.

269 {
270  if(!U32IsValidAccelMessage(lpMsg->message)) return 0;
271 
272  return NtUserTranslateAccelerator(hWnd, hAccTable, lpMsg);
273 }
BOOL WINAPI U32IsValidAccelMessage(UINT uMsg)
Definition: accel.c:166
HWND hWnd
Definition: settings.c:17
int NTAPI NtUserTranslateAccelerator(HWND Window, HACCEL Table, LPMSG Message)
Definition: accelerator.c:375
UINT message
Definition: winuser.h:3090

Referenced by TranslateAcceleratorA().

◆ U32AccelCacheAdd()

void WINAPI U32AccelCacheAdd ( HACCEL  Object,
HGLOBAL  Data 
)

Definition at line 75 of file accel.c.

76 {
77  U32_ACCEL_CACHE_ENTRY * pEntry =
79 
80  /* failed to allocate an entry - not critical */
81  if(pEntry == NULL) return;
82 
83  /* initialize the entry */
84  pEntry->Usage = 1;
85  pEntry->Object = Object;
86  pEntry->Data = Data;
87 
88  /* insert the entry into the cache */
89  pEntry->Next = U32AccelCache;
90  U32AccelCache = pEntry;
91 }
struct _USER_ACCEL_CACHE_ENTRY * Next
Definition: accel.c:44
smooth NULL
Definition: ftsmooth.c:416
_In_ LPGUID _In_ PVOID Data
Definition: classpnp.h:778
#define LMEM_FIXED
Definition: winbase.h:349
static IUnknown Object
Definition: main.c:512
HGLOBAL Data
Definition: accel.c:47
U32_ACCEL_CACHE_ENTRY * U32AccelCache
Definition: accel.c:57
ULONG_PTR Usage
Definition: accel.c:45
HLOCAL NTAPI LocalAlloc(UINT uFlags, SIZE_T dwBytes)
Definition: heapmem.c:1373
HACCEL Object
Definition: accel.c:46
Definition: accel.c:42

Referenced by U32LoadAccelerators().

◆ U32AccelCacheFind()

U32_ACCEL_CACHE_ENTRY** WINAPI U32AccelCacheFind ( HANDLE  Object,
HGLOBAL  Data 
)

Definition at line 60 of file accel.c.

61 {
62  /*
63  to avoid using a double-link list and still allow elements to be removed,
64  return a pointer to the list link that points to the desired entry
65  */
67 
68  for(; *ppEntry; ppEntry = &((*ppEntry)->Next))
69  if((*ppEntry)->Object == Object || (*ppEntry)->Data == Data) break;
70 
71  return ppEntry;
72 }
static IUnknown Object
Definition: main.c:512
U32_ACCEL_CACHE_ENTRY * U32AccelCache
Definition: accel.c:57
Definition: accel.c:42

Referenced by DestroyAcceleratorTable(), and U32LoadAccelerators().

◆ U32IsValidAccelMessage()

BOOL WINAPI U32IsValidAccelMessage ( UINT  uMsg)

Definition at line 166 of file accel.c.

167 {
168  switch(uMsg)
169  {
170  case WM_KEYDOWN:
171  case WM_KEYUP:
172  case WM_CHAR:
173  case WM_SYSCHAR:
174  case WM_SYSKEYDOWN:
175  case WM_SYSKEYUP:
176  return TRUE;
177 
178  default:
179  return FALSE;
180  }
181 }
#define TRUE
Definition: types.h:120
#define WM_CHAR
Definition: winuser.h:1699
#define WM_SYSCHAR
Definition: winuser.h:1703
#define WM_KEYDOWN
Definition: winuser.h:1697
#define WM_KEYUP
Definition: winuser.h:1698
#define WM_SYSKEYUP
Definition: winuser.h:1702
#define WM_SYSKEYDOWN
Definition: winuser.h:1701

Referenced by TranslateAcceleratorW().

◆ U32LoadAccelerators()

HACCEL WINAPI U32LoadAccelerators ( HINSTANCE  hInstance,
HRSRC  hTableRes 
)

Definition at line 94 of file accel.c.

95 {
96  HGLOBAL hAccTableData;
97  HACCEL hAccTable = NULL;
98  U32_ACCEL_CACHE_ENTRY * pEntry;
99  PE_ACCEL * pAccTableResData;
100  SIZE_T i = 0;
101  SIZE_T j = 0;
102  ACCEL * pAccTableData;
103 
104  /* load the accelerator table */
105  hAccTableData = LoadResource(hInstance, hTableRes);
106 
107  /* failure */
108  if(hAccTableData == NULL) return NULL;
109 
111 
112  /* see if this accelerator table has already been loaded */
113  pEntry = *U32AccelCacheFind(NULL, hAccTableData);
114 
115  /* accelerator table already loaded */
116  if(pEntry)
117  {
118  /* increment the reference count */
119  ++ pEntry->Usage;
120 
121  /* return the existing object */
122  hAccTable = pEntry->Object;
123 
124  /* success */
125  goto l_Leave;
126  }
127 
128  /* determine the number of entries in the table */
129  i = SizeofResource(hInstance, hTableRes) / sizeof(PE_ACCEL);
130 
131  /* allocate the buffer for the table to be passed to Win32K */
132  pAccTableData = LocalAlloc(LMEM_FIXED, i * sizeof(ACCEL));
133 
134  /* failure */
135  if(pAccTableData == NULL) goto l_Leave;
136 
137  pAccTableResData = (PE_ACCEL *)hAccTableData;
138 
139  /* copy the table */
140  for(j = 0; j < i; ++ j)
141  {
142  pAccTableData[j].fVirt = pAccTableResData[j].fVirt;
143  pAccTableData[j].key = pAccTableResData[j].key;
144  pAccTableData[j].cmd = pAccTableResData[j].cmd;
145  }
146  pAccTableData[i - 1].fVirt |= 0x80;
147 
148  /* create a new accelerator table object */
149  hAccTable = NtUserCreateAcceleratorTable(pAccTableData, i);
150 
151  /* free the buffer */
152  LocalFree(pAccTableData);
153 
154  /* failure */
155  if(hAccTable == NULL) goto l_Leave;
156 
157  /* success - cache the object */
158  U32AccelCacheAdd(hAccTable, pAccTableResData);
159 
160 l_Leave:
162  return hAccTable;
163 }
BYTE fVirt
Definition: winuser.h:2898
WORD cmd
Definition: winuser.h:2900
U32_ACCEL_CACHE_ENTRY **WINAPI U32AccelCacheFind(HANDLE Object, HGLOBAL Data)
Definition: accel.c:60
void WINAPI EnterCriticalSection(LPCRITICAL_SECTION)
void WINAPI U32AccelCacheAdd(HACCEL Object, HGLOBAL Data)
Definition: accel.c:75
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
HINSTANCE hInstance
Definition: charmap.c:20
Definition: accel.c:32
HGLOBAL WINAPI LoadResource(HINSTANCE hModule, HRSRC hRsrc)
Definition: res.c:532
smooth NULL
Definition: ftsmooth.c:416
WORD key
Definition: winuser.h:2899
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint GLint GLint j
Definition: glfuncs.h:250
#define LMEM_FIXED
Definition: winbase.h:349
HACCEL NTAPI NtUserCreateAcceleratorTable(LPACCEL Entries, ULONG EntriesCount)
Definition: accelerator.c:229
BYTE fVirt
Definition: accel.c:34
WORD cmd
Definition: accel.c:37
WORD key
Definition: accel.c:36
ULONG_PTR SIZE_T
Definition: typedefs.h:78
HLOCAL NTAPI LocalFree(HLOCAL hMem)
Definition: heapmem.c:1577
ULONG_PTR Usage
Definition: accel.c:45
CRITICAL_SECTION U32AccelCacheLock
Definition: accel.c:54
DWORD WINAPI SizeofResource(HINSTANCE hModule, HRSRC hRsrc)
Definition: res.c:568
HLOCAL NTAPI LocalAlloc(UINT uFlags, SIZE_T dwBytes)
Definition: heapmem.c:1373
void WINAPI LeaveCriticalSection(LPCRITICAL_SECTION)
HACCEL Object
Definition: accel.c:46
Definition: accel.c:42

Referenced by LoadAcceleratorsA(), and LoadAcceleratorsW().

Variable Documentation

◆ U32AccelCache

U32_ACCEL_CACHE_ENTRY* U32AccelCache = NULL

Definition at line 57 of file accel.c.

Referenced by U32AccelCacheAdd(), and U32AccelCacheFind().

◆ U32AccelCacheLock

CRITICAL_SECTION U32AccelCacheLock