|
|
|
@ -25,6 +25,7 @@ export class InputDistributor {
|
|
|
|
|
|
|
|
|
|
this.shiftIsDown = false;
|
|
|
|
|
this.altIsDown = false;
|
|
|
|
|
this.ctrlIsDown = false;
|
|
|
|
|
|
|
|
|
|
this.bindToEvents();
|
|
|
|
|
}
|
|
|
|
@ -175,6 +176,7 @@ export class InputDistributor {
|
|
|
|
|
* Handles when the page got blurred
|
|
|
|
|
*/
|
|
|
|
|
handleBlur() {
|
|
|
|
|
this.ctrlIsDown = false;
|
|
|
|
|
this.shiftIsDown = false;
|
|
|
|
|
this.altIsDown = false;
|
|
|
|
|
this.forwardToReceiver("pageBlur", {});
|
|
|
|
@ -188,6 +190,9 @@ export class InputDistributor {
|
|
|
|
|
if (event.keyCode === 16) {
|
|
|
|
|
this.shiftIsDown = true;
|
|
|
|
|
}
|
|
|
|
|
if (event.keyCode === 17) {
|
|
|
|
|
this.ctrlIsDown = true;
|
|
|
|
|
}
|
|
|
|
|
if (event.keyCode === 18) {
|
|
|
|
|
this.altIsDown = true;
|
|
|
|
|
}
|
|
|
|
@ -229,6 +234,10 @@ export class InputDistributor {
|
|
|
|
|
this.shiftIsDown = false;
|
|
|
|
|
this.forwardToReceiver("shiftUp", {});
|
|
|
|
|
}
|
|
|
|
|
if (event.keyCode === 17) {
|
|
|
|
|
this.ctrlIsDown = false;
|
|
|
|
|
this.forwardToReceiver("ctrlUp", {});
|
|
|
|
|
}
|
|
|
|
|
if (event.keyCode === 18) {
|
|
|
|
|
this.altIsDown = false;
|
|
|
|
|
this.forwardToReceiver("altUp", {});
|
|
|
|
|