From f69153844ba6ea3f5438bf2066fcc8930ff269fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrg=20Lehni?= Date: Thu, 28 Apr 2011 13:04:12 +0100 Subject: [PATCH] Make #setContextStyles() a 'protected' function. --- src/path/CompoundPath.js | 2 +- src/path/Path.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/path/CompoundPath.js b/src/path/CompoundPath.js index 15d17f52..656e8311 100644 --- a/src/path/CompoundPath.js +++ b/src/path/CompoundPath.js @@ -58,7 +58,7 @@ var CompoundPath = this.CompoundPath = PathItem.extend({ param.compound = true; for (var i = 0, l = this.children.length; i < l; i++) Item.draw(this.children[i], ctx, param); - firstChild.setContextStyles(ctx); + firstChild._setStyles(ctx); var fillColor = firstChild.getFillColor(), strokeColor = firstChild.getStrokeColor(); if (fillColor) { diff --git a/src/path/Path.js b/src/path/Path.js index dd7e5d10..e59e4511 100644 --- a/src/path/Path.js +++ b/src/path/Path.js @@ -385,7 +385,7 @@ var Path = this.Path = PathItem.extend({ var fillColor = this.getFillColor(), strokeColor = this.getStrokeColor(); if (!param.compound && (fillColor || strokeColor)) { - this.setContextStyles(ctx); + this._setStyles(ctx); ctx.save(); // If the path only defines a strokeColor or a fillColor, // draw it directly with the globalAlpha set, otherwise @@ -582,7 +582,7 @@ var Path = this.Path = PathItem.extend({ } }, - setContextStyles: function(ctx) { + _setStyles: function(ctx) { for (var i in styles) { var style = this[i](); if (style)