[qt5] use more nullptr

This commit is contained in:
Weng Xuetian 2016-03-19 16:51:40 -07:00
parent ac3640ff20
commit 328820d312
1 changed files with 5 additions and 5 deletions

View File

@ -51,29 +51,29 @@ void qEventToSym(int key, const QString& text, Qt::KeyboardModifiers mod, int& o
if (sym)
break;
QtCode2Key* result = NULL;
QtCode2Key* result = nullptr;
if (mod & Qt::KeypadModifier) {
result = qBinaryFind(keyPadQtCodeToKey, _ARRAY_END(keyPadQtCodeToKey), key);
if (result == _ARRAY_END(keyPadQtCodeToKey))
result = NULL;
result = nullptr;
}
else {
if (text.isNull()) {
result = qBinaryFind(qtCodeToKeyBackup, _ARRAY_END(qtCodeToKeyBackup), key);
if (result == _ARRAY_END(qtCodeToKeyBackup))
result = NULL;
result = nullptr;
}
if (!result) {
result = qBinaryFind(qtCodeToKey, _ARRAY_END(qtCodeToKey), key);
if (result == _ARRAY_END(qtCodeToKey))
result = NULL;
result = nullptr;
}
if (!result) {
result = qBinaryFind(keyPadQtCodeToKey, _ARRAY_END(keyPadQtCodeToKey), key);
if (result == _ARRAY_END(keyPadQtCodeToKey))
result = NULL;
result = nullptr;
}
}