Commit f2915c77 authored by Christian Winter's avatar Christian Winter

wip. mousehandler legacy bug

parent c5e9c94d
......@@ -8,6 +8,8 @@
this.views = [];
this.views.push(new View());
this.views.push(new View());
this.views.push(new View());
this.views.push(new View());
this.currentView = this.views[this.views.length - 1];
......
......@@ -43,11 +43,8 @@ class Input {
Logic.currentState.keyDown(e.keyCode);
Application.currentView.keyDown(e.keyCode);
if (!MouseHandler.canvasFocused) {
if (e.keyCode == Key.Enter) {
Application.currentView.canvas.focus();
Application.redrawAllViews();
}
if (e.keyCode == Key.Enter) {
Application.currentView.canvas.focus();
}
if (e.keyCode != Key.F12
......@@ -56,8 +53,7 @@ class Input {
&& e.keyCode != Key.F5
&& e.keyCode == Key.Tab
)
if (MouseHandler.canvasFocused)
e.preventDefault();
e.preventDefault();
if (
e.keyCode == Key.D && this.isKeyDown(Key.Control)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment