Merge pull request #8542 from imgntn/nobackspace

No more delete with backspace in edit.js
This commit is contained in:
James B. Pollack 2016-08-29 17:31:44 -07:00 committed by GitHub
commit ed2ebd122b

View file

@ -803,7 +803,7 @@ function setupModelMenus() {
menuName: "Edit", menuName: "Edit",
menuItemName: "Delete", menuItemName: "Delete",
shortcutKeyEvent: { shortcutKeyEvent: {
text: "backspace" text: "delete"
}, },
afterItem: "Entities", afterItem: "Entities",
grouping: "Advanced" grouping: "Advanced"
@ -1215,7 +1215,7 @@ Controller.keyReleaseEvent.connect(function (event) {
cameraManager.keyReleaseEvent(event); cameraManager.keyReleaseEvent(event);
} }
// since sometimes our menu shortcut keys don't work, trap our menu items here also and fire the appropriate menu items // since sometimes our menu shortcut keys don't work, trap our menu items here also and fire the appropriate menu items
if (event.text === "BACKSPACE" || event.text === "DELETE") { if (event.text === "DELETE") {
deleteSelectedEntities(); deleteSelectedEntities();
} else if (event.text === "ESC") { } else if (event.text === "ESC") {
selectionManager.clearSelections(); selectionManager.clearSelections();