Added warning before leaving the page
This commit is contained in:
parent
0833727d96
commit
0ba03cdece
|
@ -42,6 +42,15 @@ var loader;
|
||||||
var coins = [];
|
var coins = [];
|
||||||
var previousTime;
|
var previousTime;
|
||||||
|
|
||||||
|
window.onbeforeunload = function() {
|
||||||
|
|
||||||
|
if (initMainScene !== initPeach && initMainScene !== initSponza && Coin.total !== 9) {
|
||||||
|
|
||||||
|
return 'Warning : you are going to leave the page and abort the current test !';
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
init();
|
init();
|
||||||
|
|
Loading…
Reference in New Issue