From ea934c1a02dc2a9f19508db63a977e658775d68a Mon Sep 17 00:00:00 2001 From: Brian Federle Date: Thu, 11 Oct 2012 13:22:19 -0700 Subject: [PATCH] Update advanced search styling - Add cancel button - Move search buttons to the right --- ui/css/cloudstack3.css | 17 +++++++++++++++++ ui/scripts/ui/widgets/listView.js | 8 ++++++++ 2 files changed, 25 insertions(+) diff --git a/ui/css/cloudstack3.css b/ui/css/cloudstack3.css index c822ce0d524..8616fe78e9f 100644 --- a/ui/css/cloudstack3.css +++ b/ui/css/cloudstack3.css @@ -2759,6 +2759,7 @@ div.toolbar div.button.add span { } #advanced_search input[type=submit] { + float: right; background: url(../images/bg-gradients.png) 0px -220px; /*+box-shadow:0px 2px 5px #858585;*/ -moz-box-shadow: 0px 2px 5px #858585; @@ -2792,6 +2793,22 @@ div.toolbar div.button.add span { box-shadow: inset 0px 2px 3px #000000; } +#advanced_search .button.cancel { + background: url(noen); + color: #9A9A9A; + font-size: 12px; + float: right; + /*+placement:shift -32px 13px;*/ + position: relative; + left: -32px; + top: 13px; + font-weight: bold; +} + +#advanced_search .button.cancel:hover { + color: #494949; +} + /*** Panel controls*/ #browser div.panel div.toolbar div.panel-controls { float: right; diff --git a/ui/scripts/ui/widgets/listView.js b/ui/scripts/ui/widgets/listView.js index 726a8a2ed9e..2a6919d54a6 100644 --- a/ui/scripts/ui/widgets/listView.js +++ b/ui/scripts/ui/widgets/listView.js @@ -1568,6 +1568,14 @@ .appendTo($form) .val('Search'); + // Cancel button + $form.append( + $('
').addClass('button cancel').html(_l('label.cancel')) + .click(function() { + closeAdvancedSearch(); + }) + ); + $form.submit(function() { form.completeAction($formContainer); });