Added alert and corrected bug

This commit is contained in:
Thomas FORGIONE 2015-04-24 17:15:00 +02:00
parent 74e16eb14d
commit af0314af9c
2 changed files with 9 additions and 1 deletions

View File

@ -51,7 +51,8 @@ var PointerCamera = function() {
listenerTarget.addEventListener('mousedown', function(event) { if (event.which == 1) onMouseDown(event);}, false);
listenerTarget.addEventListener('mousemove', function(event) { if (event.which == 1) onMouseMove(event);}, false);
listenerTarget.addEventListener('mouseup', onMouseUp, false);
listenerTarget.addEventListener('mouseout', onMouseUp, false);
// listenerTarget.addEventListener('mouseup', function() { console.log("mouseup");}, false);
// listenerTarget.addEventListener('mouseout', onMouseUp, false);
this.collisions = true;
}

View File

@ -15,6 +15,7 @@ var loader;
var container_size = {width: 1024, height: 576};
var prev = {x:0, y:0, go:false};
var showArrows = true;
var beenFullscreen = false;
init();
animate();
@ -221,6 +222,12 @@ function init() {
}
function fullscreen() {
if (!beenFullscreen) {
beenFullscreen = true;
alert('To quit fullscren mode, type ESC key');
}
container.style.position = "absolute";
container.style.cssFloat = "top-left";
container.style.top = "0px";