dropped inactivity alert
This commit is contained in:
parent
d8e544c639
commit
e8f1b73994
8
main.js
8
main.js
|
@ -26,7 +26,6 @@ var codelanguages = ["xml", "js", "sql"];
|
||||||
var currentnote = null;
|
var currentnote = null;
|
||||||
var fileindex = 0;
|
var fileindex = 0;
|
||||||
var workerid = null;
|
var workerid = null;
|
||||||
var inactivityid = null;
|
|
||||||
var backup = "";
|
var backup = "";
|
||||||
var localdata = null;
|
var localdata = null;
|
||||||
var saved = true;
|
var saved = true;
|
||||||
|
@ -1972,11 +1971,6 @@ function postpone()
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function inactivityalert()
|
|
||||||
{
|
|
||||||
alert("Last save was one hour ago. Should you refresh?");
|
|
||||||
}
|
|
||||||
|
|
||||||
function save()
|
function save()
|
||||||
{
|
{
|
||||||
clearTimeout(workerid);
|
clearTimeout(workerid);
|
||||||
|
@ -2042,8 +2036,6 @@ function save()
|
||||||
{
|
{
|
||||||
console.log("...data saved on server");
|
console.log("...data saved on server");
|
||||||
saved = true;
|
saved = true;
|
||||||
clearTimeout(inactivityid);
|
|
||||||
inactivityid = setTimeout(inactivityalert, 60 * 60 * 1000);
|
|
||||||
})
|
})
|
||||||
.catch(remotecallfailed)
|
.catch(remotecallfailed)
|
||||||
.finally(() =>
|
.finally(() =>
|
||||||
|
|
Loading…
Reference in New Issue