![]() |
#1 |
Scout
Join Date: Feb 2010
Location: Russia
Posts: 27
![]() |
[sdl][S/O/FA/other]Alt and Meta keypress modifiers are ignored.
Greetings.
There is a bug in the SDL port that prevents alt/meta modifiers from being recognized. As the code in question is shared by many variants, I think here is a good place for a bug report. Correct me if I'm wrong. ![]() In the sdl_keypress function (main-sdl.c) we find this innocently looking code: Code:
/* Store the value of various modifier keys */ bool mc = (bool)(keysym.mod & (KMOD_CTRL)); bool ms = (bool)(keysym.mod & (KMOD_SHIFT)); bool ma = (bool)(keysym.mod & (KMOD_ALT)); bool mm = (bool)(keysym.mod & (KMOD_META)); This can be fixed either by using int instead of bool for flags: Code:
... int mc = (keysym.mod & (KMOD_CTRL)); ... Code:
... bool mc = (bool)((keysym.mod & (KMOD_CTRL) != KMOD_NONE); ... ![]() |
![]() |
![]() |
![]() |
#2 |
Vanilla maintainer
Join Date: Apr 2007
Location: Canberra, Australia
Age: 58
Posts: 9,529
Donated: $60
![]() ![]() |
Thanks - fixed in FA and O dev versions.
__________________
One for the Dark Lord on his dark throne In the Land of Mordor where the Shadows lie. |
![]() |
![]() |
![]() |
#3 |
Angband Devteam member
|
Finally fixed in V (staging branch - will be in nightlies shortly).
|
![]() |
![]() |
![]() |
#4 |
Sangband 1.x Maintainer
Join Date: Apr 2007
Posts: 523
![]() |
I guess I'm slow on the uptake; I guess I can fix this tonight when I get home
![]()
__________________
a chunk of Bronze {These look tastier than they are. !E} 3 blank Parchments (Vellum) {No french novels please.} |
![]() |
![]() |
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Down with the SDL! | Pete Mack | Development | 0 | August 13, 2009 04:26 |
feature request: add home inventory stat modifiers/flags/etc | bebo | Vanilla | 2 | July 17, 2009 00:36 |
SDL sound | Nick | Development | 1 | July 16, 2009 21:14 |
Ubuntu SDL Help? | benhamill | Vanilla | 12 | February 24, 2009 21:19 |