DXR will be turned off on Tuesday, December 29th. It will redirect to Searchfox.
See the announcement on Discourse.

DXR is a code search and navigation tool aimed at making sense of large projects. It supports full-text and regex searches as well as structural queries.

Mercurial (cdf352f02ac4)

VCS Links

Line Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65
/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

#include "../ShortcutKeys.h"

namespace mozilla {

ShortcutKeyData ShortcutKeys::sInputHandlers[] = {
    {u"keypress", nullptr, u"c", u"accel", u"cmd_copy"},
    {u"keypress", nullptr, u"x", u"accel", u"cmd_cut"},
    {u"keypress", nullptr, u"v", u"accel", u"cmd_paste"},
    {u"keypress", nullptr, u"z", u"accel", u"cmd_undo"},
    {u"keypress", nullptr, u"z", u"accel,shift", u"cmd_redo"},
    {u"keypress", nullptr, u"a", u"accel", u"cmd_selectAll"},

    {nullptr, nullptr, nullptr, nullptr, nullptr}};

ShortcutKeyData ShortcutKeys::sTextAreaHandlers[] = {
    {u"keypress", nullptr, u"c", u"accel", u"cmd_copy"},
    {u"keypress", nullptr, u"x", u"accel", u"cmd_cut"},
    {u"keypress", nullptr, u"v", u"accel", u"cmd_paste"},
    {u"keypress", nullptr, u"z", u"accel", u"cmd_undo"},
    {u"keypress", nullptr, u"z", u"accel,shift", u"cmd_redo"},
    {u"keypress", nullptr, u"a", u"accel", u"cmd_selectAll"},

    {nullptr, nullptr, nullptr, nullptr, nullptr}};

ShortcutKeyData ShortcutKeys::sBrowserHandlers[] = {
#include "../ShortcutKeyDefinitionsForBrowserCommon.h"

    {u"keypress", u"VK_PAGE_UP", nullptr, nullptr, u"cmd_scrollPageUp"},
    {u"keypress", u"VK_PAGE_DOWN", nullptr, nullptr, u"cmd_scrollPageDown"},
    {u"keypress", u"VK_HOME", nullptr, nullptr, u"cmd_scrollTop"},
    {u"keypress", u"VK_END", nullptr, nullptr, u"cmd_scrollBottom"},
    {u"keypress", u"VK_LEFT", nullptr, u"alt", u"cmd_moveLeft2"},
    {u"keypress", u"VK_RIGHT", nullptr, u"alt", u"cmd_moveRight2"},
    {u"keypress", u"VK_LEFT", nullptr, u"alt,shift", u"cmd_selectLeft2"},
    {u"keypress", u"VK_RIGHT", nullptr, u"alt,shift", u"cmd_selectRight2"},
    {u"keypress", u"VK_LEFT", nullptr, u"shift", u"cmd_selectLeft"},
    {u"keypress", u"VK_RIGHT", nullptr, u"shift", u"cmd_selectRight"},
    {u"keypress", u"VK_UP", nullptr, u"alt,shift", u"cmd_selectUp2"},
    {u"keypress", u"VK_DOWN", nullptr, u"alt,shift", u"cmd_selectDown2"},
    {u"keypress", u"VK_UP", nullptr, u"shift", u"cmd_selectUp"},
    {u"keypress", u"VK_DOWN", nullptr, u"shift", u"cmd_selectDown"},
    {u"keypress", u"VK_UP", nullptr, u"accel", u"cmd_moveUp2"},
    {u"keypress", u"VK_DOWN", nullptr, u"accel", u"cmd_moveDown2"},

    {nullptr, nullptr, nullptr, nullptr, nullptr}};

ShortcutKeyData ShortcutKeys::sEditorHandlers[] = {
    {u"keypress", nullptr, u" ", u"shift", u"cmd_scrollPageUp"},
    {u"keypress", nullptr, u" ", nullptr, u"cmd_scrollPageDown"},
    {u"keypress", nullptr, u"z", u"accel", u"cmd_undo"},
    {u"keypress", nullptr, u"z", u"accel,shift", u"cmd_redo"},
    {u"keypress", nullptr, u"x", u"accel", u"cmd_cut"},
    {u"keypress", nullptr, u"c", u"accel", u"cmd_copy"},
    {u"keypress", nullptr, u"v", u"accel", u"cmd_paste"},
    {u"keypress", nullptr, u"v", u"accel,shift", u"cmd_pasteNoFormatting"},
    {u"keypress", nullptr, u"a", u"accel", u"cmd_selectAll"},
    {u"keypress", nullptr, u"v", u"accel,alt,shift", u"cmd_pasteNoFormatting"},

    {nullptr, nullptr, nullptr, nullptr, nullptr}};

}  // namespace mozilla