From 36f337d43f6a870cfaeabe982cd40983a2e4ea56 Mon Sep 17 00:00:00 2001 From: "bzbarsky%mit.edu" Date: Tue, 12 Oct 2004 03:21:13 +0000 Subject: [PATCH] Look at style height in addition to the height attribute for vertical marquees. Bug 262708, r=doron, sr=jst git-svn-id: svn://10.0.0.236/trunk@163574 18797224-902f-48f8-a5cc-f745e15eee43 --- .../src/xbl-marquee/resources/content/xbl-marquee.xml | 7 ++++++- mozilla/layout/style/xbl-marquee/xbl-marquee.xml | 7 ++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/mozilla/layout/html/document/src/xbl-marquee/resources/content/xbl-marquee.xml b/mozilla/layout/html/document/src/xbl-marquee/resources/content/xbl-marquee.xml index 69768d5f14b..540e9ae5d4b 100644 --- a/mozilla/layout/html/document/src/xbl-marquee/resources/content/xbl-marquee.xml +++ b/mozilla/layout/html/document/src/xbl-marquee/resources/content/xbl-marquee.xml @@ -204,7 +204,12 @@ if ((this.directionField == "up") || (this.directionField == "down")) { // "", 0 and empty height should default to 200px - var height = (this.getAttribute("height") != "0" && this.getAttribute("height")) || "200px"; + var height = + (this.getAttribute("height") != "0" && + this.getAttribute("height")) || + (document.defaultView.getComputedStyle(this,"").height != "0px" && + document.defaultView.getComputedStyle(this,"").height) || + "200px"; // support % heights if (/%/.test(height)) { diff --git a/mozilla/layout/style/xbl-marquee/xbl-marquee.xml b/mozilla/layout/style/xbl-marquee/xbl-marquee.xml index 69768d5f14b..540e9ae5d4b 100644 --- a/mozilla/layout/style/xbl-marquee/xbl-marquee.xml +++ b/mozilla/layout/style/xbl-marquee/xbl-marquee.xml @@ -204,7 +204,12 @@ if ((this.directionField == "up") || (this.directionField == "down")) { // "", 0 and empty height should default to 200px - var height = (this.getAttribute("height") != "0" && this.getAttribute("height")) || "200px"; + var height = + (this.getAttribute("height") != "0" && + this.getAttribute("height")) || + (document.defaultView.getComputedStyle(this,"").height != "0px" && + document.defaultView.getComputedStyle(this,"").height) || + "200px"; // support % heights if (/%/.test(height)) {