Merge pull request #15923 from PrestonB1123/fixShortcuts

BUGZ-991: Added conditionals to shortcuts to remove overlap
This commit is contained in:
Zach Fox 2019-07-15 15:23:58 -07:00 committed by GitHub
commit aed94a3a66
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -14,11 +14,11 @@
(function () { // BEGIN LOCAL_SCOPE
var snapActivateSound = SoundCache.getSound(Script.resourcesPath() + "sounds/snapshot/snap.wav");
function keyPressEvent(event) {
if (event.text.toUpperCase() === "B" && event.isControl) {
if (event.text.toUpperCase() === "B" && event.isControl && !event.isShifted && !event.isAlt && !event.isCommand) {
Window.openWebBrowser();
} else if (event.text.toUpperCase() === "N" && event.isControl) {
} else if (event.text.toUpperCase() === "N" && event.isControl && !event.isShifted && !event.isAlt && !event.isCommand) {
Users.toggleIgnoreRadius();
} else if (event.text.toUpperCase() === "P") {
} else if (event.text.toUpperCase() === "P" && !event.isControl && !event.isShifted && !event.isAlt && !event.isCommand) {
Audio.playSound(snapActivateSound, {
position: { x: MyAvatar.position.x, y: MyAvatar.position.y, z: MyAvatar.position.z },
localOnly: true,