Skip to content

Commit

Permalink
Fixed branch recompile bug: #297
Browse files Browse the repository at this point in the history
  • Loading branch information
xeolabs committed Oct 11, 2013
1 parent 475e224 commit 9f81ccb
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
7 changes: 3 additions & 4 deletions api/latest/scenejs.js
Expand Up @@ -7364,11 +7364,9 @@ SceneJS.Node.prototype._compileNodes = function () {
child.branchDirty = child.branchDirty || this.branchDirty; // Compile subnodes if scene branch dirty

if (child.dirty || child.branchDirty || this._engine.sceneDirty) { // Compile nodes that are flagged dirty

child._compile();
child.dirty = false;
child.branchDirty = false;

child._compile();
}
}

Expand All @@ -7378,6 +7376,7 @@ SceneJS.Node.prototype._compileNodes = function () {
};



/**
* Destroys this node. It is marked for destruction; when the next scene traversal begins (or the current one ends)
* it will be destroyed and removed from it's parent.
Expand Down Expand Up @@ -10542,7 +10541,7 @@ new (function () {
SceneJS.Name.prototype._compile = function () {

this._engine.display.name = coreStack[stackLen++] = this._core;

// (Re)build name path
var path = [];
var name;
Expand Down
5 changes: 2 additions & 3 deletions src/core/scene/node.js
Expand Up @@ -1309,11 +1309,9 @@ SceneJS.Node.prototype._compileNodes = function () {
child.branchDirty = child.branchDirty || this.branchDirty; // Compile subnodes if scene branch dirty

if (child.dirty || child.branchDirty || this._engine.sceneDirty) { // Compile nodes that are flagged dirty

child._compile();
child.dirty = false;
child.branchDirty = false;

child._compile();
}
}

Expand All @@ -1323,6 +1321,7 @@ SceneJS.Node.prototype._compileNodes = function () {
};



/**
* Destroys this node. It is marked for destruction; when the next scene traversal begins (or the current one ends)
* it will be destroyed and removed from it's parent.
Expand Down

0 comments on commit 9f81ccb

Please sign in to comment.