Skip to content
This repository has been archived by the owner on Jul 3, 2019. It is now read-only.

Commit

Permalink
Cleanup.
Browse files Browse the repository at this point in the history
  • Loading branch information
Tobias Schneider committed Sep 18, 2013
1 parent 0030272 commit 878bccc
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
2 changes: 2 additions & 0 deletions src/flash/display/DisplayObject.js
Original file line number Diff line number Diff line change
Expand Up @@ -520,6 +520,7 @@ var DisplayObjectDefinition = (function () {

this._invalidate();
this._bounds = null;

this._scaleX = val;
this._updateCurrentTransform();
},
Expand All @@ -532,6 +533,7 @@ var DisplayObjectDefinition = (function () {

this._invalidate();
this._bounds = null;

this._scaleY = val;
this._updateCurrentTransform();
},
Expand Down
12 changes: 7 additions & 5 deletions src/flash/display/Stage.js
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ var StageDefinition = (function () {
this._invalidObjects.push(displayObject);
},

_processInvalidRegions: function() {
_processInvalidRegions: function processInvalidRegions() {
var objects = this._invalidObjects;
var regions = [];

Expand Down Expand Up @@ -165,15 +165,16 @@ var StageDefinition = (function () {
var neighbours = this._qtree.retrieve(xMin, yMin, xMax, yMax);
for (var j = 0; j < neighbours.length; j++) {
var item = neighbours[j];
var neighbour = item.obj;

if (neighbour._invalid || (xMin > item.xMax) || (xMax < item.xMin) ||
(yMin > item.yMax) || (yMax < item.yMin))
if (item.obj._invalid || (xMin > item.x + item.width) ||
(xMax < item.x) ||
(yMin > item.y + item.height) ||
(yMax < item.y))
{
continue;
}

neighbour._invalid = true;
item.obj._invalid = true;

numInvalidObjects++;
}
Expand Down Expand Up @@ -222,6 +223,7 @@ var StageDefinition = (function () {
} else {
interactiveObject = this;
}

while (ancestor) {
if (flash.display.InteractiveObject.class.isInstanceOf(ancestor) &&
!flash.display.SimpleButton.class.isInstanceOf(ancestor) &&
Expand Down

0 comments on commit 878bccc

Please sign in to comment.