From 2dbef68feeb78d4691ce466c45e0a7cccf13872e Mon Sep 17 00:00:00 2001 From: lindsayevans Date: Thu, 21 May 2009 13:20:27 +0800 Subject: [PATCH] Fixes SVG capability detection bug in Safari 3.0.4 (http://github.com/DmitryBaranovskiy/raphael/issues/#issue/14) Signed-off-by: Dmitry Baranovskiy --- raphael.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/raphael.js b/raphael.js index 36d76d7..a7222bb 100644 --- a/raphael.js +++ b/raphael.js @@ -18,7 +18,8 @@ window.Raphael = (function () { availableAnimAttrs = {cx: "number", cy: "number", fill: "colour", "fill-opacity": "number", "font-size": "number", height: "number", opacity: "number", path: "path", r: "number", rotation: "csv", rx: "number", ry: "number", scale: "csv", stroke: "colour", "stroke-opacity": "number", "stroke-width": "number", translation: "csv", width: "number", x: "number", y: "number"}, events = ["click", "dblclick", "mousedown", "mousemove", "mouseout", "mouseover", "mouseup"]; R.version = "0.7.4"; - R.type = (window.SVGAngle ? "SVG" : "VML"); + R.type = (window.SVGAngle || document.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure", "1.1") + ? "SVG" : "VML"); R.svg = !(R.vml = R.type == "VML"); R.idGenerator = 0; R.fn = {}; -- 2.39.2