From 391d42ae101d62f041749c384bb6810e88dbaaa8 Mon Sep 17 00:00:00 2001 From: Michael M Slusarz Date: Fri, 23 Oct 2009 13:28:09 -0600 Subject: [PATCH] Better close filter display --- imp/js/DimpBase.js | 13 +++++-------- imp/templates/index/index-dimp.inc | 1 + imp/themes/screen-dimp.css | 5 +++++ 3 files changed, 11 insertions(+), 8 deletions(-) diff --git a/imp/js/DimpBase.js b/imp/js/DimpBase.js index aaa9ddd4c..db849962c 100644 --- a/imp/js/DimpBase.js +++ b/imp/js/DimpBase.js @@ -1385,10 +1385,8 @@ var DimpBase = { } if (this.isSearch()) { - DimpCore.DMenu.disable('qsearch_icon', true, false); - DimpCore.DMenu.disable('qsearch_icon', false, false); this.resetSelected(); - $('qsearch', 'qsearch_input').invoke('show'); + $('qsearch', 'qsearch_icon', 'qsearch_input').invoke('show'); if (!noload) { this.loadMailbox(this.search ? this.search.mbox : 'INBOX'); } @@ -1403,7 +1401,7 @@ var DimpBase = { $('qsearch_input').setValue(d ? DIMP.text.search + ' (' + $('ctx_qsearchby_' + DIMP.conf.qsearchfield).getText() + ')' : ''); [ $('qsearch') ].invoke(d ? 'removeClassName' : 'addClassName', 'qsearchActive'); if ($('qsearch_input').visible()) { - $('qsearch_close').hide(); + $('qsearch_close').hide().next().hide(); } }, @@ -1413,11 +1411,9 @@ var DimpBase = { if (hideall) { $('qsearch').hide(); } else { - $('qsearch_close').show(); - $('qsearch_input').hide(); + $('qsearch_close').show().next().show(); + $('qsearch_icon', 'qsearch_input').invoke('hide'); } - DimpCore.DMenu.disable('qsearch_icon', true, true); - DimpCore.DMenu.disable('qsearch_icon', false, true); }, /* Enable/Disable DIMP action buttons as needed. */ @@ -1797,6 +1793,7 @@ var DimpBase = { break; case 'qsearch_close': + case 'qsearch_close_filter': this.quicksearchClear(); e.stop(); return; diff --git a/imp/templates/index/index-dimp.inc b/imp/templates/index/index-dimp.inc index 9e29e4a7d..3984c2344 100644 --- a/imp/templates/index/index-dimp.inc +++ b/imp/templates/index/index-dimp.inc @@ -171,6 +171,7 @@ function _simpleButton($id, $text, $image) + diff --git a/imp/themes/screen-dimp.css b/imp/themes/screen-dimp.css index e8f000901..93ce28f7e 100644 --- a/imp/themes/screen-dimp.css +++ b/imp/themes/screen-dimp.css @@ -794,6 +794,11 @@ a.address:hover img { margin-bottom: 1px; padding: 0; } +#qsearch_close_filter { + cursor: pointer; + padding-right: 3px; + vertical-align: middle; +} .qsearchFocus, .qsearchFocus #qsearch_icon, .qsearchFocus #qsearch_input { background-color: #fff !important; } -- 2.11.0