From f37b1e87e6fec295df2dd97ed39725860ec26270 Mon Sep 17 00:00:00 2001 From: Thomas Berezansky Date: Thu, 11 Oct 2012 13:34:32 -0400 Subject: [PATCH] Stop highlighting indicators The way that commands were highlighted when selected, highlighted both the indicators and the buttons. Change to only hightlight the tabbed buttons. Signed-off-by: Thomas Berezansky Signed-off-by: Ben Shum Signed-off-by: Kathy Lussier --- Open-ILS/xul/staff_client/server/patron/display.js | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/Open-ILS/xul/staff_client/server/patron/display.js b/Open-ILS/xul/staff_client/server/patron/display.js index 03c350fa54..33fead8acc 100644 --- a/Open-ILS/xul/staff_client/server/patron/display.js +++ b/Open-ILS/xul/staff_client/server/patron/display.js @@ -692,14 +692,12 @@ patron.display.prototype = { this.skip_hide_summary = false; dont_hide_summary = true; } - this.controller.view.cmd_patron_checkout.setAttribute('style',''); - this.controller.view.cmd_patron_items.setAttribute('style',''); - this.controller.view.cmd_patron_edit.setAttribute('style',''); - this.controller.view.cmd_patron_other.setAttribute('style',''); - this.controller.view.cmd_patron_holds.setAttribute('style',''); - this.controller.view.cmd_patron_bills.setAttribute('style',''); - this.controller.view.cmd_standing_penalties.setAttribute('style',''); - this.controller.view[ btn ].setAttribute('style','background: blue; color: white;'); + var buttons = document.getElementsByTagName('button'); + for(var i = 0; i < buttons.length; i++) { + var command = buttons[i].getAttribute('command'); + if(command == btn) buttons[i].setAttribute('style','background: blue; color: white;'); + else buttons[i].setAttribute('style',''); + } var auto_hide_patron_sidebar = String( this.OpenILS.data.hash.aous['circ.auto_hide_patron_summary'] ) == 'true'; var x = document.getElementById('splitter_grippy'); if (x && auto_hide_patron_sidebar && ! dont_hide_summary) { -- 2.11.0