effectively fixes tab locking with the MARC editor, and makes the previous fix with...
authorphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 28 Jan 2011 17:37:32 +0000 (17:37 +0000)
committerphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 28 Jan 2011 17:37:32 +0000 (17:37 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@19321 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/xul/staff_client/chrome/content/OpenILS/global_util.js

index c20d270..364d573 100644 (file)
@@ -46,6 +46,7 @@
             if (typeof xulG.unlock_tab == 'function') {
                 dump('\twith xulG.lock_tab\n');
                 xulG.lock_tab();
+                window.oils_lock++; // different window scope than the chrome of xulG.lock_tab
             } else {
                 dump('\twithout xulG.lock_tab\n');
                 oils_unsaved_data_V();
@@ -64,6 +65,8 @@
             if (typeof xulG.unlock_tab == 'function') {
                 dump('\twith xulG.unlock_tab\n');
                 xulG.unlock_tab();
+                window.oils_lock--; // different window scope than the chrome of xulG.unlock_tab
+                if (window.oils_lock < 0) { window.oils_lock = 0; }
             } else {
                 dump('\twithout xulG.unlock_tab\n');
                 oils_unsaved_data_P();