Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jason Beetham
wine
Commits
a49bb266
Commit
a49bb266
authored
25 years ago
by
Joshua Thielen
Committed by
Alexandre Julliard
25 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Fixed DestroyAcceleratorTable and implemented CreateAcceleratorTableW.
parent
a2b938c2
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
include/winuser.h
+3
-0
3 additions, 0 deletions
include/winuser.h
loader/resource.c
+56
-3
56 additions, 3 deletions
loader/resource.c
relay32/user32.spec
+1
-1
1 addition, 1 deletion
relay32/user32.spec
with
60 additions
and
4 deletions
include/winuser.h
+
3
−
0
View file @
a49bb266
...
...
@@ -2921,6 +2921,9 @@ WORD WINAPI CascadeWindows(HWND, UINT, const LPRECT, UINT, const HWND *);
INT
WINAPI
CopyAcceleratorTableA
(
HACCEL
,
LPACCEL
,
INT
);
INT
WINAPI
CopyAcceleratorTableW
(
HACCEL
,
LPACCEL
,
INT
);
#define CopyAcceleratorTable WINELIB_NAME_AW(CopyAcceleratorTable)
HACCEL
WINAPI
CreateAcceleratorTableA
(
LPACCEL
,
INT
);
HACCEL
WINAPI
CreateAcceleratorTableW
(
LPACCEL
,
INT
);
#define CreateAcceleratorTable WINELIB_NAME_AW(CreateAcceleratorTable)
HICON
WINAPI
CreateIconIndirect
(
LPICONINFO
);
BOOL
WINAPI
DestroyAcceleratorTable
(
HACCEL
);
BOOL
WINAPI
EnumDisplayMonitors
(
HDC
,
LPRECT
,
MONITORENUMPROC
,
LPARAM
);
...
...
This diff is collapsed.
Click to expand it.
loader/resource.c
+
56
−
3
View file @
a49bb266
...
...
@@ -31,6 +31,7 @@
#include
"libres.h"
#include
"winerror.h"
#include
"debugstr.h"
#include
"winnls.h"
DECLARE_DEBUG_CHANNEL
(
accel
)
DECLARE_DEBUG_CHANNEL
(
resource
)
...
...
@@ -777,6 +778,60 @@ HACCEL WINAPI CreateAcceleratorTableA(LPACCEL lpaccel, INT cEntries)
return
hAccel
;
}
/*********************************************************************
* CreateAcceleratorTableW (USER32.64)
*
*
*/
HACCEL
WINAPI
CreateAcceleratorTableW
(
LPACCEL
lpaccel
,
INT
cEntries
)
{
HACCEL
hAccel
;
LPACCEL16
accel
;
int
i
;
char
ckey
;
/* Do parameter checking just in case someone's trying to be
funny. */
if
(
cEntries
<
1
)
{
WARN_
(
accel
)(
"Application sent invalid parameters (%p %d).
\n
"
,
lpaccel
,
cEntries
);
SetLastError
(
ERROR_INVALID_PARAMETER
);
return
(
HACCEL
)
NULL
;
}
FIXME_
(
accel
)(
"should check that the accelerator descriptions are valid,"
" return NULL and SetLastError() if not.
\n
"
);
/* Allocate memory and copy the table. */
hAccel
=
GlobalAlloc16
(
0
,
cEntries
*
sizeof
(
ACCEL16
));
TRACE_
(
accel
)(
"handle %x
\n
"
,
hAccel
);
if
(
!
hAccel
)
{
ERR_
(
accel
)(
"Out of memory.
\n
"
);
SetLastError
(
ERROR_NOT_ENOUGH_MEMORY
);
return
(
HACCEL
)
NULL
;
}
accel
=
GlobalLock16
(
hAccel
);
for
(
i
=
0
;
i
<
cEntries
;
i
++
)
{
accel
[
i
].
fVirt
=
lpaccel
[
i
].
fVirt
;
if
(
!
(
accel
[
i
].
fVirt
&
FVIRTKEY
)
)
{
ckey
=
(
char
)
lpaccel
[
i
].
key
;
if
(
!
MultiByteToWideChar
(
CP_ACP
,
MB_PRECOMPOSED
,
&
ckey
,
1
,
&
accel
[
i
].
key
,
1
))
WARN_
(
accel
)(
"Error converting ASCII accelerator table to Unicode"
);
}
else
accel
[
i
].
key
=
lpaccel
[
i
].
key
;
accel
[
i
].
cmd
=
lpaccel
[
i
].
cmd
;
}
/* Set the end-of-table terminator. */
accel
[
cEntries
-
1
].
fVirt
|=
0x80
;
TRACE_
(
accel
)(
"Allocated accelerator handle %x
\n
"
,
hAccel
);
return
hAccel
;
}
/******************************************************************************
* DestroyAcceleratorTable [USER32.130]
...
...
@@ -792,9 +847,7 @@ HACCEL WINAPI CreateAcceleratorTableA(LPACCEL lpaccel, INT cEntries)
*/
BOOL
WINAPI
DestroyAcceleratorTable
(
HACCEL
handle
)
{
FIXME_
(
accel
)(
"(0x%x): stub
\n
"
,
handle
);
/* FIXME: GlobalFree16(handle); */
return
TRUE
;
return
GlobalFree16
(
handle
);
}
/**********************************************************************
...
...
This diff is collapsed.
Click to expand it.
relay32/user32.spec
+
1
−
1
View file @
a49bb266
...
...
@@ -66,7 +66,7 @@ init MAIN_UserInit
62 stdcall CopyRect(ptr ptr) CopyRect
63 stdcall CountClipboardFormats() CountClipboardFormats
64 stdcall CreateAcceleratorTableA(ptr long) CreateAcceleratorTableA
65 st
ub
CreateAcceleratorTableW
65 st
dcall CreateAcceleratorTableW(ptr long)
CreateAcceleratorTableW
66 stdcall CreateCaret(long long long long) CreateCaret
67 stdcall CreateCursor(long long long long long ptr ptr) CreateCursor
68 stub CreateDesktopA
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment