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);
<groupbox flex="0">
<caption label="&staff.cat.marcedit.options.label;"/>
<hbox flex="1">
- <checkbox persist="checked" accesskey='&staff.cat.marcedit.stackSubfields.accesskey;' label="&staff.cat.marcedit.stackSubfields.label;" onclick="stackSubfields(this);" checked="false" id="stackSubfields"/>
+ <checkbox persist="checked" accesskey='&staff.cat.marcedit.stackSubfields.accesskey;' label="&staff.cat.marcedit.stackSubfields.label;" oncommand="stackSubfields(this);" checked="false" id="stackSubfields"/>
<button label="&staff.cat.marcedit.validate.label;" accesskey="&staff.cat.marcedit.validate.accesskey;" oncommand="validateAuthority(this);"/>
<button id="save-button" accesskey="&staff.cat.marcedit.save-button.accesskey;"/>
<button label="&staff.cat.marcedit.help.label;" accesskey="&staff.cat.marcedit.help.accesskey;"