Bug 1689573 - Make `WidgetKeyboardEvent::GetCommandStr()` map empty string to commands never executed r=smaug

Not mapping them causes creating shorter command list than expected.

Differential Revision: https://phabricator.services.mozilla.com/D103465
This commit is contained in:
Masayuki Nakano 2021-01-29 22:26:57 +00:00
Родитель b9efbca10c
Коммит f7b2e8084b
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -1197,7 +1197,7 @@ uint32_t WidgetKeyboardEvent::GetFallbackKeyCodeOfPunctuationKey(
/* static */ const char* WidgetKeyboardEvent::GetCommandStr(Command aCommand) {
#define NS_DEFINE_COMMAND(aName, aCommandStr) , #aCommandStr
#define NS_DEFINE_COMMAND_WITH_PARAM(aName, aCommandStr, aParam) , #aCommandStr
#define NS_DEFINE_COMMAND_NO_EXEC_COMMAND(aName)
#define NS_DEFINE_COMMAND_NO_EXEC_COMMAND(aName) , ""
static const char* const kCommands[] = {
"" // DoNothing
#include "mozilla/CommandList.h"