From 333a8e95d426e92906085c937a3dade06bc52394 Mon Sep 17 00:00:00 2001 From: mattias Date: Tue, 8 May 2018 08:31:28 +0000 Subject: [PATCH] lcl: gtk2: debug altgr git-svn-id: trunk@57838 - --- lcl/interfaces/gtk2/gtk2proc.inc | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/lcl/interfaces/gtk2/gtk2proc.inc b/lcl/interfaces/gtk2/gtk2proc.inc index beb1912c55..6a0b93aacd 100644 --- a/lcl/interfaces/gtk2/gtk2proc.inc +++ b/lcl/interfaces/gtk2/gtk2proc.inc @@ -2362,7 +2362,7 @@ begin if AHandleDown then begin {$IFDEF VerboseKeyboard} - DebugLn('[HandleGTKKeyUpDown] GDK_KEY_PRESS VKey=',dbgs(VKey),' SysKey=',dbgs(SysKey)); + DebugLn('[HandleGTKKeyUpDown] GDK_KEY_PRESS VKey=',dbgs(VKey),' SysKey=',dbgs(SysKey),' Shift=',dbgs(Shift),' KCInfo=Key1=',KCInfo.VKey1,',Key2=',KCInfo.VKey2,',Flags=',hexstr(KCInfo.Flags,2)); {$ENDIF} Msg.CharCode := VKey; @@ -2418,19 +2418,19 @@ begin if ABeforeEvent then begin // try to get the UTF8 representation of the key - if im_context_string <> '' then - begin - Character := UTF8Copy(im_context_string,1,1); - im_context_string:='';// clear, to avoid sending again - end + if im_context_string <> '' then + begin + Character := UTF8Copy(im_context_string,1,1); + im_context_string:='';// clear, to avoid sending again + end + else + begin + KeyPressesChar := GetSpecialChar; + if KeyPressesChar <> #0 then + Character := KeyPressesChar else - begin - KeyPressesChar := GetSpecialChar; - if KeyPressesChar <> #0 then - Character := KeyPressesChar - else - Character := ''; - end; + Character := ''; + end; {$IFDEF VerboseKeyboard} debugln('[HandleGTKKeyUpDown] GDK_KEY_PRESS UTF8="',DbgStr(Character),'"',