From b44b9db5ef8ef34304b4e8fab0754e059155e500 Mon Sep 17 00:00:00 2001 From: phasefx Date: Tue, 10 Mar 2009 13:39:32 +0000 Subject: [PATCH] use oncommand rather onclick here for keyboard access. But interestingly, the timing for DOM updates appears to happen differently between oncommand and onclick, so the element's .checked (and @checked) get updated after the oncommand but before the onclick. So I threw a negation in front of the .checked test git-svn-id: svn://svn.open-ils.org/ILS/trunk@12483 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/xul/staff_client/server/cat/marcedit.js | 2 +- Open-ILS/xul/staff_client/server/cat/marcedit.xul | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Open-ILS/xul/staff_client/server/cat/marcedit.js b/Open-ILS/xul/staff_client/server/cat/marcedit.js index dbd8dcb6bd..36d2a5eca1 100644 --- a/Open-ILS/xul/staff_client/server/cat/marcedit.js +++ b/Open-ILS/xul/staff_client/server/cat/marcedit.js @@ -1229,7 +1229,7 @@ function stackSubfields(checkbox) { var list = document.getElementsByAttribute('name','sf_box'); var o = 'vertical'; - if (checkbox.checked) o = 'horizontal'; + if (!checkbox.checked /* this property gets changed after the oncommand handler, so we're testing for the opposite value */) o = 'horizontal'; for (var i = 0; i < list.length; i++) { if (list[i]) list[i].setAttribute('orient',o); diff --git a/Open-ILS/xul/staff_client/server/cat/marcedit.xul b/Open-ILS/xul/staff_client/server/cat/marcedit.xul index e72d37909e..671b036c6c 100644 --- a/Open-ILS/xul/staff_client/server/cat/marcedit.xul +++ b/Open-ILS/xul/staff_client/server/cat/marcedit.xul @@ -24,7 +24,7 @@ - +