diff --git a/Gruntfile.js b/Gruntfile.js index 32fe511..6754431 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -124,7 +124,7 @@ }, jshint: { options: { - jshintrc: '.jshintrc' + jshintrc: './.jshintrc' }, source: srcFiles.filter(function(v) { return v.match(/(Intro|Outro|Spine|Pixi)\.js$/) === null; }).concat('Gruntfile.js'), test: { diff --git a/Gruntfile.js b/Gruntfile.js index 32fe511..6754431 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -124,7 +124,7 @@ }, jshint: { options: { - jshintrc: '.jshintrc' + jshintrc: './.jshintrc' }, source: srcFiles.filter(function(v) { return v.match(/(Intro|Outro|Spine|Pixi)\.js$/) === null; }).concat('Gruntfile.js'), test: { diff --git a/src/pixi/display/DisplayObjectContainer.js b/src/pixi/display/DisplayObjectContainer.js index 9f32a51..44cbaa1 100644 --- a/src/pixi/display/DisplayObjectContainer.js +++ b/src/pixi/display/DisplayObjectContainer.js @@ -37,9 +37,8 @@ */ PIXI.DisplayObjectContainer.prototype.addChild = function(child) { - if(child.parent !== undefined) + if(child.parent && child.parent !== this) { - //// COULD BE THIS??? child.parent.removeChild(child); // return; diff --git a/Gruntfile.js b/Gruntfile.js index 32fe511..6754431 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -124,7 +124,7 @@ }, jshint: { options: { - jshintrc: '.jshintrc' + jshintrc: './.jshintrc' }, source: srcFiles.filter(function(v) { return v.match(/(Intro|Outro|Spine|Pixi)\.js$/) === null; }).concat('Gruntfile.js'), test: { diff --git a/src/pixi/display/DisplayObjectContainer.js b/src/pixi/display/DisplayObjectContainer.js index 9f32a51..44cbaa1 100644 --- a/src/pixi/display/DisplayObjectContainer.js +++ b/src/pixi/display/DisplayObjectContainer.js @@ -37,9 +37,8 @@ */ PIXI.DisplayObjectContainer.prototype.addChild = function(child) { - if(child.parent !== undefined) + if(child.parent && child.parent !== this) { - //// COULD BE THIS??? child.parent.removeChild(child); // return; diff --git a/src/pixi/renderers/webgl/WebGLGraphics.js b/src/pixi/renderers/webgl/WebGLGraphics.js index 50ba448..bb90529 100644 --- a/src/pixi/renderers/webgl/WebGLGraphics.js +++ b/src/pixi/renderers/webgl/WebGLGraphics.js @@ -110,7 +110,7 @@ { PIXI.WebGLGraphics.buildRectangle(data, graphics._webGL); } - else if(data.type === PIXI.Graphics.CIRC || data.type === PIXI.Graphics.ELIP); + else if(data.type === PIXI.Graphics.CIRC || data.type === PIXI.Graphics.ELIP) { PIXI.WebGLGraphics.buildCircle(data, graphics._webGL); }