On 3/10/07, Pavel Janík <[EMAIL PROTECTED]> wrote:
first: thank you very much for join Mac port!
Your welcome.
Your patch works here with Czech keyboard layout. Minor nit: when you press Ctrl+A to mark all text, it crashes:
OK. The code using UCKeyTranslate is taken from Apple's Tech Q&A QA1446 (http://developer.apple.com/qa/qa2005/qa1446.html) and works on my machine, but maybe it is needed to check uchrHandle before calling UCKeyTranslate().
>>>> HandleTSMEvent >>>> HandleUnicodeForKeyEvent in Handle_TextInputUnicodeForKeyEvent, uniChar is 0001=, in original Keyboard Event, uniChar is 0001=, mac char is 0001=, key code is 0, modifier is 4096before UCKeyTranslate Program received signal EXC_BAD_ACCESS, Could not access memory. Reason: KERN_PROTECTION_FAILURE at address: 0x00000000 0x0124bf18 in HandleUnicodeForKeyEvent (inHandlerCallRef=0xbfffdc30, inEvent=0x23216230, inUserData=0x2c79b10) at /Users/pavel/BUILD/AQUA/ BuildDir/ooo_SRC680_m202_src/vcl/aqua/source/window/salframe.cxx:1807 1807 1, &dummy, &uc); (gdb) list 1802 fprintf(stderr, "before UCKeyTranslate\n"); 1803 1804 UCKeyTranslate((UCKeyboardLayout*)*uchrHandle, keyCode, 1805 kUCKeyActionDisplay, (modifier & ~controlKey) >> 8, 1806 keyboardType, kUCKeyTranslateNoDeadKeysMask, &dummy, 1807 1, &dummy, &uc); 1808 fprintf(stderr, "after UCKeyTranslate\n"); 1809 fprintf(stderr, ", it's a Control-%c\n", uc); 1810 } 1811 (gdb) print uchrHandle $1 = (Handle) 0x0 (gdb) And some notes at the end: - please end fprintf's with \n ;-)
Yes agreed, but I just use Apple's sample code there :) Cheers, -- Etsushi Kato [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
