зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1333097 - remove kAutoDetect usage from XULMenuItemAccessible; r=bz
Instead of requiring nsString to determine the radix that we're using, we'll just try all the cases in sequence and take the first one that works.
This commit is contained in:
Родитель
37f705d303
Коммит
cc58e177e9
|
@ -214,7 +214,10 @@ XULMenuitemAccessible::KeyboardShortcut() const
|
|||
nsAutoString keyCodeStr;
|
||||
keyElm->GetAttr(kNameSpaceID_None, nsGkAtoms::keycode, keyCodeStr);
|
||||
nsresult errorCode;
|
||||
key = keyStr.ToInteger(&errorCode, kAutoDetect);
|
||||
key = keyStr.ToInteger(&errorCode, kRadix10);
|
||||
if (NS_FAILED(errorCode)) {
|
||||
key = keyStr.ToInteger(&errorCode, kRadix16);
|
||||
}
|
||||
} else {
|
||||
key = keyStr[0];
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче