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
0debf422
Commit
0debf422
authored
24 years ago
by
Stephane Lussier
Committed by
Alexandre Julliard
24 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Fixed AltGr key handling.
parent
8903137c
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
dlls/x11drv/x11drv_main.c
+0
-2
0 additions, 2 deletions
dlls/x11drv/x11drv_main.c
windows/x11drv/keyboard.c
+17
-1
17 additions, 1 deletion
windows/x11drv/keyboard.c
with
17 additions
and
3 deletions
dlls/x11drv/x11drv_main.c
+
0
−
2
View file @
0debf422
...
...
@@ -156,8 +156,6 @@ static void process_attach(void)
CLIPBOARD_Driver
=
&
X11DRV_CLIPBOARD_Driver
;
WND_Driver
=
&
X11DRV_WND_Driver
;
putenv
(
"XKB_DISABLE="
);
/* Disable XKB extension if present. */
/* Open display */
if
(
!
(
display
=
TSXOpenDisplay
(
Options
.
display
)))
...
...
This diff is collapsed.
Click to expand it.
windows/x11drv/keyboard.c
+
17
−
1
View file @
0debf422
...
...
@@ -450,7 +450,7 @@ static WORD EVENT_event_to_vkey( XKeyEvent *e)
return
keyc2vkey
[
e
->
keycode
];
}
static
BOOL
NumState
=
FALSE
,
CapsState
=
FALSE
;
static
BOOL
NumState
=
FALSE
,
CapsState
=
FALSE
,
AltGrState
=
FALSE
;
/**********************************************************************
* KEYBOARD_GenerateMsg
...
...
@@ -583,6 +583,16 @@ void X11DRV_KEYBOARD_HandleEvent( WND *pWnd, XKeyEvent *event )
ascii_chars
=
TSXLookupString
(
event
,
Str
,
1
,
&
keysym
,
&
cs
);
TRACE_
(
key
)(
"EVENT_key : state = %X
\n
"
,
event
->
state
);
/* If the state mask for AltGr hasn't been set yet, it's probably
because the X server/client are using XKB extension. With XKB extension
AltGr is mapped to a Group index. The group index is set in bits 13-14
of event->state field.
Ref: X Keyboard Extension: Library specification (section 14.1.1 and 17.1.1) */
if
(
AltGrState
&&
(
AltGrMask
==
0
))
AltGrMask
=
event
->
state
&
0x6000
;
if
(
keysym
==
XK_Mode_switch
)
{
TRACE_
(
key
)(
"Alt Gr key event received
\n
"
);
...
...
@@ -593,6 +603,12 @@ void X11DRV_KEYBOARD_HandleEvent( WND *pWnd, XKeyEvent *event )
force_extended
=
TRUE
;
X11DRV_KEYBOARD_HandleEvent
(
pWnd
,
event
);
force_extended
=
FALSE
;
/* Here we save the pressed/released state of the AltGr key, to be able to
identify the group index associated with AltGr on the next key pressed *
see comment above. */
AltGrState
=
(
event
->
type
==
KeyPress
)
?
TRUE
:
FALSE
;
return
;
}
...
...
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