[Date Prev][Date Next][Thread Prev][Thread Next][Thread Index]
[XaraXtreme-commits] Commit Complete
Commit by : luke
Repository : xara
Revision : 1622
Date : Mon Jul 31 16:36:31 BST 2006
Changed paths:
M /Trunk/XaraLX/tools/texttool.cpp
Fix some keypress ownership issues in texttool
Diff:
Index: Trunk/XaraLX/tools/texttool.cpp
===================================================================
--- Trunk/XaraLX/tools/texttool.cpp (revision 1621)
+++ Trunk/XaraLX/tools/texttool.cpp (revision 1622)
@@ -1165,8 +1165,8 @@
{
TRACEUSER("wuerthne", _T("not char"));
- // We own all keys that don't have constrain or alt pressed
- if( !pKeyPress->IsConstrain() && !pKeyPress->IsAlternative() )
+ // We own all keys that don't have constrain or alt pressed and aren't extended chars
+ if( !pKeyPress->IsConstrain() && !pKeyPress->IsAlternative() && !pKeyPress->IsExtended() )
return true;
return pKeyPress->GetUnicode() == _T(' '); // always claim the Space key (tool switch)
@@ -1182,8 +1182,10 @@
(pKeyPress->IsAlternative() && pKeyPress->IsConstrain()) ) // Ctrl & left alt down
{
WCHAR UnicodeValue = pKeyPress->GetUnicode();
- TRACEUSER("wuerthne", _T("UnicodeValue from keypress event = %04x"), UnicodeValue);
- if (HandleDeadKeys(pKeyPress, &UnicodeValue))
+ TRACEUSER("wuerthne", _T("UnicodeValue from keypress event = %04x %d"), UnicodeValue, pKeyPress->IsExtended() );
+
+ // Extanded keys shouldn't produce a character
+ if (HandleDeadKeys(pKeyPress, &UnicodeValue) || pKeyPress->IsExtended())
return TRUE;
else
{
Xara