commit 241b60dd0d48f3898f3c4935fe232479db3b3f07
parent 4bc37c2c51e42e0caaba86413f343214c23e3f28
Author: Alexander Burger <abu@software-lab.de>
Date: Sun, 23 Jun 2013 14:07:06 +0200
Suppress update of currently modified input field
Diffstat:
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/lib/form.js b/lib/form.js
@@ -1,4 +1,4 @@
-/* 11may13abu
+/* 23jun13abu
* (c) Software Lab. Alexander Burger
*/
@@ -8,7 +8,7 @@ FormReq.upload.addEventListener("load", dropLoad, false);
var Btn = [];
var Queue = [];
-var SesId, Key, InBtn, Auto, Drop, Hint, Hints, Item, Beg, End;
+var SesId, Key, InBtn, Auto, Chg, Drop, Hint, Hints, Item, Beg, End;
function inBtn(flg) {InBtn = flg;}
@@ -26,6 +26,7 @@ function formKey(event) {
}
function fldChg(field) {
+ Chg = field;
if (!InBtn && Key != 13)
post(field.form, null, null);
return true;
@@ -128,6 +129,10 @@ function post(form, exe, file) {
}
if (!(fld = document.getElementById(fld)))
continue;
+ if (fld == Chg) {
+ Chg = null;
+ continue;
+ }
if (fld.tagName == "SPAN") {
if (i != txt.length && txt[i].charAt(0) == "=")
++i;