svnno****@sourc*****
svnno****@sourc*****
2011年 3月 30日 (水) 23:35:38 JST
Revision: 2532 http://sourceforge.jp/projects/sie/svn/view?view=rev&revision=2532 Author: dhrname Date: 2011-03-30 23:35:38 +0900 (Wed, 30 Mar 2011) Log Message: ----------- NAIBU._setPaint関数の最適化 Modified Paths: -------------- branches/07x/074/org/w3c/dom/svg.js Modified: branches/07x/074/org/w3c/dom/svg.js =================================================================== --- branches/07x/074/org/w3c/dom/svg.js 2011-03-30 14:29:45 UTC (rev 2531) +++ branches/07x/074/org/w3c/dom/svg.js 2011-03-30 14:35:38 UTC (rev 2532) @@ -2380,6 +2380,8 @@ style = tod.defaultView.getComputedStyle(tar, ""), fill = style.getPropertyCSSValue("fill"), stroke = style.getPropertyCSSValue("stroke"), + fp = fill.paintType, + sp = stroke.paintType, fillElement, tgebtfill, fc, num = /*CSSPrimitiveValue.CSS_NUMBER*/ 1, t, evtt, fillOpacity, strs, cursor, vis, disp, @@ -2387,8 +2389,8 @@ if (!el) { return; } - if (fill.paintType === /*SVGPaint.SVG_PAINTTYPE_RGBCOLOR*/ 1 || fill.paintType === /*SVGPaint.SVG_PAINTTYPE_CURRENTCOLOR*/ 102) { - if (fill.paintType === /*SVGPaint.SVG_PAINTTYPE_CURRENTCOLOR*/ 102) { + if ((fp === /*SVGPaint.SVG_PAINTTYPE_RGBCOLOR*/ 1) || (fp === /*SVGPaint.SVG_PAINTTYPE_CURRENTCOLOR*/ 102)) { + if (fp === /*SVGPaint.SVG_PAINTTYPE_CURRENTCOLOR*/ 102) { /*再度、設定。css.jsのsetPropertyを参照*/ style.setProperty("color", style.getPropertyValue("color")); } @@ -2438,8 +2440,8 @@ } else { el.filled = "false"; } - if (stroke.paintType === /*SVGPaint.SVG_PAINTTYPE_RGBCOLOR*/ 1 || stroke.paintType === /*SVGPaint.SVG_PAINTTYPE_CURRENTCOLOR*/ 102) { - if (stroke.paintType === /*SVGPaint.SVG_PAINTTYPE_CURRENTCOLOR*/ 102) { + if ((sp === /*SVGPaint.SVG_PAINTTYPE_RGBCOLOR*/ 1) || (sp === /*SVGPaint.SVG_PAINTTYPE_CURRENTCOLOR*/ 102)) { + if (sp === /*SVGPaint.SVG_PAINTTYPE_CURRENTCOLOR*/ 102) { /*再度、設定。css.jsのsetPropertyを参照*/ style.setProperty("color", style.getPropertyValue("color")); } @@ -2518,7 +2520,7 @@ } else if (disp !== "inline-block") { el.style.display = "inline-block"; } - tod = el = fill = stroke = style = cursor = tar = matrix = vis = disp = null; + tod = el = fill = stroke = sp = fp = style = cursor = tar = matrix = vis = disp = null; }; function SVGPathElement() {