svnno****@sourc*****
svnno****@sourc*****
2011年 5月 5日 (木) 20:02:33 JST
Revision: 2658 http://sourceforge.jp/projects/sie/svn/view?view=rev&revision=2658 Author: dhrname Date: 2011-05-05 20:02:33 +0900 (Thu, 05 May 2011) Log Message: ----------- SVGStyleElementにLinkStyleを継承させた Modified Paths: -------------- branches/07x/077/org/w3c/dom/svg.js Modified: branches/07x/077/org/w3c/dom/svg.js =================================================================== --- branches/07x/077/org/w3c/dom/svg.js 2011-05-05 10:42:56 UTC (rev 2657) +++ branches/07x/077/org/w3c/dom/svg.js 2011-05-05 11:02:33 UTC (rev 2658) @@ -1901,12 +1901,19 @@ */ function SVGStyleElement() { SVGElement.apply(this); + LinkStyle.apply(this); + /*LinkStyleに関しては、以下のの仕様を参照のこと。なお、これはSVG DOMでは継承されていないので要注意。 + *CSS2 1. Document Object Model Style Sheets + * 1.3. Document Extensions + * Interface LinkStyle (introduced in DOM Level 2) + * http://www.w3.org/TR/DOM-Level-2-Style/stylesheets.html#StyleSheets-LinkStyle + */ /*以下はそれぞれ、属性の値に対応している*/ /*DOMString*/ this.xmlspace; /*DOMString*/ this.type = "text/css"; /*DOMString*/ this.media; /*DOMString*/ this.title; - SVGURIReference.apply(this, arguments); + SVGURIReference.apply(this); this.addEventListener("DOMAttrModified", function(evt){ if (evt.attrName === "type") { evt.target.type = evt.newValue; @@ -1919,11 +1926,8 @@ var tar = evt.target, style = tar._text, tod = tar.ownerDocument; - console.log(style); NAIBU._temp_doc = tod; - console.log(tod.styleSheets); - tod.styleSheets[tod.styleSheets.length] = DOMImplementation.createCSSStyleSheet(tar.title, tar.media); - alert(style); + tar.sheet = tod.styleSheets[tod.styleSheets.length] = DOMImplementation.createCSSStyleSheet(tar.title, tar.media); tod.documentElement._svgload_limited--; if (tod.documentElement._svgload_limited < 0) { evt = tod.createEvent("SVGEvents");