From b539c7afc3e5bdeeff96356ce071d1f62ceb58fe Mon Sep 17 00:00:00 2001 From: "ben%netscape.com" Date: Thu, 9 Mar 2000 07:46:00 +0000 Subject: [PATCH] fixes for search panel appearance, 28103 r=german, a=jevering git-svn-id: svn://10.0.0.236/trunk@62461 18797224-902f-48f8-a5cc-f745e15eee43 --- .../browser/resources/content/navigator.xul | 2 +- .../xpfe/browser/resources/skin/navigator.css | 23 ---------------- .../resources/locale/en-US/search-panel.dtd | 6 ++--- .../search/resources/search-panel.js | 21 ++++++++------- .../search/resources/search-panel.xul | 16 ++--------- .../components/search/resources/search.css | 27 ++++++++++++++++++- mozilla/xpfe/global/resources/skin/global.css | 15 +++++++++++ 7 files changed, 58 insertions(+), 52 deletions(-) diff --git a/mozilla/xpfe/browser/resources/content/navigator.xul b/mozilla/xpfe/browser/resources/content/navigator.xul index 883f549b968..c251e959924 100644 --- a/mozilla/xpfe/browser/resources/content/navigator.xul +++ b/mozilla/xpfe/browser/resources/content/navigator.xul @@ -374,7 +374,7 @@ Contributor(s): ______________________________________. --> - diff --git a/mozilla/xpfe/browser/resources/skin/navigator.css b/mozilla/xpfe/browser/resources/skin/navigator.css index 1e637508fd5..59c9f670e9c 100644 --- a/mozilla/xpfe/browser/resources/skin/navigator.css +++ b/mozilla/xpfe/browser/resources/skin/navigator.css @@ -99,29 +99,6 @@ box#searchbutton { list-style-image:url("chrome://global/skin/scroll-down.gif"); } -#search-button { - background-color: #99CCCC; - padding: 2px; - border: 1px outset #99CCCC; - -moz-border-radius: 4px; -} - -#search-button:active { - padding: 3px 1px 1px 3px; - border: 1px inset #CCFFFF; -} - -#search-button:hover { - background-color: #CCFFFF; - border: 1px outset #CCFFFF; -} - -#search-button:hover:active { - background-color: #CCFFFF; - border: 1px inset #CCFFFF; -} - - #action-popup { list-style-image:url("chrome://global/skin/scroll-down.gif"); background-color: #99CCCC; diff --git a/mozilla/xpfe/components/search/resources/locale/en-US/search-panel.dtd b/mozilla/xpfe/components/search/resources/locale/en-US/search-panel.dtd index 086b6871942..2c3de027478 100755 --- a/mozilla/xpfe/components/search/resources/locale/en-US/search-panel.dtd +++ b/mozilla/xpfe/components/search/resources/locale/en-US/search-panel.dtd @@ -19,14 +19,14 @@ - Contributor(s): --> - + - - + + \ No newline at end of file diff --git a/mozilla/xpfe/components/search/resources/search-panel.js b/mozilla/xpfe/components/search/resources/search-panel.js index 4d8235518e3..79d31ad80bb 100644 --- a/mozilla/xpfe/components/search/resources/search-panel.js +++ b/mozilla/xpfe/components/search/resources/search-panel.js @@ -131,13 +131,6 @@ function SearchPanelStartup() //set to default value 'the web' //hack: hardcoded postion in here replace with a function that finds the entry 'the web' - // set the category name on the advanced panel - var categoryText = categoryList.options[ categoryList.selectedIndex ].text; - var textElement = document.getElementById( "categoryNameText" ); - textElement.setAttribute( "value", categoryText ); - //set the category name on the settings button - settingsButton.value = settingsButtonText + categoryText; - for( var i = 0; i < categoryList.options.length; i++ ) { if( ( lastCategoryName == "" && categoryList.options[i].value == "NC:SearchEngineRoot" ) || @@ -145,6 +138,14 @@ function SearchPanelStartup() categoryList.selectedIndex = i; } } + + // set the category name on the advanced panel + var categoryText = categoryList.options[ categoryList.selectedIndex ].text; + var textElement = document.getElementById( "categoryNameText" ); + textElement.setAttribute( "value", categoryText ); + //set the category name on the settings button + settingsButton.value = settingsButtonText + categoryText + "..."; + if( lastCategoryName == "" ) lastCategoryName = "NC:SearchEngineRoot"; else @@ -467,14 +468,14 @@ function doSearch() engineURIs[engineURIs.length] = treeItem.getAttribute( "id" ); } else { - dump("*** multiple search engines present, selecting the netscape search engine\n"); + dump("*** multiple engines present, none selected, selecting the netscape search engine\n"); for( var i = 0; i < treeChildrenNode.childNodes.length; i++ ) { var currItem = treeChildrenNode.childNodes[i]; dump("*** the current URI is = " + currItem.getAttribute("id") + "\n"); - if( currItem.getAttribute("id").indexOf("Open_Directory") != -1 ) { + if( currItem.getAttribute("id").indexOf("NetscapeSearchMain") != -1 ) { - engineURIs[engineURIs.length] = treeItem.getAttribute("id"); + engineURIs[engineURIs.length] = currItem.getAttribute("id"); break; } } diff --git a/mozilla/xpfe/components/search/resources/search-panel.xul b/mozilla/xpfe/components/search/resources/search-panel.xul index f96cbe3eda7..565a5d685b3 100644 --- a/mozilla/xpfe/components/search/resources/search-panel.xul +++ b/mozilla/xpfe/components/search/resources/search-panel.xul @@ -30,32 +30,20 @@ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" align="vertical" - class="dialog" onload="SearchPanelStartup();" onunload="SearchPanelShutdown();"> - - - - - &search.results.tab; - &search.advanced.tab; - - - - - - - &within.label; diff --git a/mozilla/xpfe/components/search/resources/search.css b/mozilla/xpfe/components/search/resources/search.css index fe98c443e7d..7ed47d6312b 100755 --- a/mozilla/xpfe/components/search/resources/search.css +++ b/mozilla/xpfe/components/search/resources/search.css @@ -35,7 +35,8 @@ treecol.checkboxColumn { } box.spaced { - padding-bottom: 5px; + padding-top: 5px; + paddimg-bottom: 2px; } box#engineTabs { @@ -64,3 +65,27 @@ titledbutton.engine[loading="true"] { titledbutton.iconic { list-style-image: url("resource:/res/rdf/document.gif") ! important ; } + +treeitem > treerow.searchresult > treecell > titledbutton { + cursor: pointer; +} + +treeitem > treerow.searchresult > treecell { + color: black; + text-decoration: none; +} + +treeitem > treerow.searchresult > treecell:hover { + color: blue; + text-decoration: underline; +} + +treeitem > treerow.searchresult > treecell > titledbutton:active { + color: red; + text-decoration: underline; +} + +/*undo regular search tree selection look*/ +treeitem[selected="true"] > treerow.searchresult { + background-color: transparent; +} \ No newline at end of file diff --git a/mozilla/xpfe/global/resources/skin/global.css b/mozilla/xpfe/global/resources/skin/global.css index 583085d74a8..16443c52673 100644 --- a/mozilla/xpfe/global/resources/skin/global.css +++ b/mozilla/xpfe/global/resources/skin/global.css @@ -317,6 +317,21 @@ titledbutton.button32[disabled="true"]:active { background-image:url("chrome://global/skin/button32-bg-disabled.gif"); } +/* non-iconic toolbar button (e.g. search) */ +titledbutton.toolbar-non-iconic { + background-color: #99CCCC; + padding: 2px; + margin: 0px 2px 0px 2px; + border: 1px outset #99CCCC; + -moz-border-radius: 4px; + font-weight: bold; +} + +titledbutton.toolbar-non-iconic:active { + padding: 3px 1px 1px 3px; + border: 1px inset #CCFFFF; +} + /** * Throbber */