lightspeedretail/webstore — Issue #217: Rare Mac redefine error in Qcodo
Author: ktwbc
Created: 2012-02-23 15:26:53+00:00
State: open
Labels: Bug Fix

// Key-Specific Events (EnterKey, EscapeKey, UpArrowKey, DownArrowKey, etc.)
if (QApplication::IsBrowser(QBrowserType::Macintosh)) {
class QEnterKeyEvent extends QKeyPressEvent {
protected $strCondition = 'event.keyCode == 13';
}
class QEscapeKeyEvent extends QKeyPressEvent {
protected $strCondition = 'event.keyCode == 27';
}
class QUpArrowKeyEvent extends QKeyPressEvent {
protected $strCondition = 'event.keyCode == 38';
}
class QDownArrowKeyEvent extends QKeyPressEvent {
protected $strCondition = 'event.keyCode == 40';
}
}
if (!QApplication::IsBrowser(QBrowserType::Macintosh)) {
class QEnterKeyEvent extends QKeyDownEvent {
protected $strCondition = 'event.keyCode == 13';
}
class QEscapeKeyEvent extends QKeyDownEvent {
protected $strCondition = 'event.keyCode == 27';
}
class QUpArrowKeyEvent extends QKeyDownEvent {
protected $strCondition = 'event.keyCode == 38';
}
class QDownArrowKeyEvent extends QKeyDownEvent {
protected $strCondition = 'event.keyCode == 40';
}
}