From fc442271b79dfa4e7e5d29d941dbeb8ae9982bb5 Mon Sep 17 00:00:00 2001 From: Tim Schaub Date: Wed, 12 Dec 2007 23:16:08 +0000 Subject: [PATCH] try namespaced element first for ie7 - what a godawful mess git-svn-id: http://svn.openlayers.org/trunk/openlayers@5390 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf --- tests/Layer/test_Vector.html | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/tests/Layer/test_Vector.html b/tests/Layer/test_Vector.html index a13f20a15d..a5bc98c99c 100644 --- a/tests/Layer/test_Vector.html +++ b/tests/Layer/test_Vector.html @@ -315,9 +315,15 @@ "given graphicHeight and graphicWidth, both are set: width"); feature.style = customStyle5; layer.drawFeature(feature); - var fill = root.firstChild.getElementsByTagName("fill")[0]; - if (fill == null) fill = root.firstChild.getElementsByTagName("v:fill"); - var opacity = fill.getAttribute('opacity'); + var fill = root.firstChild.getElementsByTagName("v:fill")[0]; + var opacity; + if(fill) { + opacity = fill.getAttribute('opacity'); + } + if(opacity === undefined) { + fill = root.firstChild.getElementsByTagName("fill")[0]; + opacity = fill.getAttribute('opacity'); + } t.eq(opacity, customStyle5.graphicOpacity, "graphicOpacity correctly set");