Cocoa: fix Option + any key in key event

Unmodified key code should be used.

Task-number: QTBUG-33200
Change-Id: I9cf91030e80336772c05a40efae52f3b8734cbdb
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
bb10
Liang Qi 2014-06-03 09:26:03 +02:00
parent fbac55fe59
commit ebc729b3c3
1 changed files with 1 additions and 1 deletions

View File

@ -1316,7 +1316,7 @@ static QTabletEvent::TabletDevice wacomTabletDevice(NSEvent *theEvent)
QChar ch = QChar::ReplacementCharacter;
int keyCode = Qt::Key_unknown;
if ([characters length] != 0) {
if ((modifiers & Qt::MetaModifier) && ([charactersIgnoringModifiers length] != 0))
if (((modifiers & Qt::MetaModifier) || (modifiers & Qt::AltModifier)) && ([charactersIgnoringModifiers length] != 0))
ch = QChar([charactersIgnoringModifiers characterAtIndex:0]);
else
ch = QChar([characters characterAtIndex:0]);