From 286123ea27eb7f1d793a113dfdddcda609a98dc3 Mon Sep 17 00:00:00 2001 From: "danm%netscape.com" Date: Thu, 25 Apr 2002 01:22:13 +0000 Subject: [PATCH] force popup widget to be invisible when the menu is not explicitly open. bug 120155 r=bryner,hyatt a=scc git-svn-id: svn://10.0.0.236/trunk@119807 18797224-902f-48f8-a5cc-f745e15eee43 --- .../autocomplete/resources/content/autocomplete.css | 8 +++++++- .../autocomplete/resources/content/autocomplete.xml | 4 +++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/mozilla/xpfe/components/autocomplete/resources/content/autocomplete.css b/mozilla/xpfe/components/autocomplete/resources/content/autocomplete.css index 2e6df5b7087..fc4a8692531 100644 --- a/mozilla/xpfe/components/autocomplete/resources/content/autocomplete.css +++ b/mozilla/xpfe/components/autocomplete/resources/content/autocomplete.css @@ -7,6 +7,12 @@ display: -moz-popup !important; } +/* the C++ implementation of widgets is too eager to make popups visible. + this causes problems (bug 120155 and others), thus this workaround: */ +.autocomplete-result-popup[hidden="true"] { + visibility: hidden; +} + /* The following rule is here to fix bug 96899 (and now 117952). Somehow trees create a situation in which a popupset flows itself as if its popup child is directly within it @@ -19,4 +25,4 @@ popupset { treecolpicker { display: none; -} \ No newline at end of file +} diff --git a/mozilla/xpfe/components/autocomplete/resources/content/autocomplete.xml b/mozilla/xpfe/components/autocomplete/resources/content/autocomplete.xml index 0e0d50a72d7..f814381a9f9 100644 --- a/mozilla/xpfe/components/autocomplete/resources/content/autocomplete.xml +++ b/mozilla/xpfe/components/autocomplete/resources/content/autocomplete.xml @@ -30,7 +30,7 @@ xbl:inherits="open,hidden=disablehistory" anonid="historydropmarker"/> - + @@ -999,6 +999,7 @@ var w = this.boxObject.width; if (w != this.resultsPopup.boxObject.width) this.resultsPopup.setAttribute("width", w); + this.resultsPopup.removeAttribute("hidden"); this.resultsPopup.showPopup(this, -1, -1, "popup", "bottomleft", "topleft"); this.mMenuOpen = true; } @@ -1010,6 +1011,7 @@