diff --git a/src/core/sprites/Sprite.js b/src/core/sprites/Sprite.js index 626c920..fa4fff6 100644 --- a/src/core/sprites/Sprite.js +++ b/src/core/sprites/Sprite.js @@ -510,7 +510,7 @@ } }; -Sprite.prototype.setTexture = function () +Sprite.prototype.setTexture = function () { window.console.warn('setTexture is now deprecated, please use the texture property, e.g : sprite.texture = texture; '); }; diff --git a/src/core/sprites/Sprite.js b/src/core/sprites/Sprite.js index 626c920..fa4fff6 100644 --- a/src/core/sprites/Sprite.js +++ b/src/core/sprites/Sprite.js @@ -510,7 +510,7 @@ } }; -Sprite.prototype.setTexture = function () +Sprite.prototype.setTexture = function () { window.console.warn('setTexture is now deprecated, please use the texture property, e.g : sprite.texture = texture; '); }; diff --git a/src/extras/TilingSprite.js b/src/extras/TilingSprite.js index ff34740..a8bb4f5 100644 --- a/src/extras/TilingSprite.js +++ b/src/extras/TilingSprite.js @@ -445,7 +445,7 @@ * Checks if a point is inside this tiling sprite * @param point {Point} the point to check */ -TilingSprite.prototype.hitTest = function( point ) +TilingSprite.prototype.containsPoint = function( point ) { this.worldTransform.applyInverse(point, tempPoint); diff --git a/src/core/sprites/Sprite.js b/src/core/sprites/Sprite.js index 626c920..fa4fff6 100644 --- a/src/core/sprites/Sprite.js +++ b/src/core/sprites/Sprite.js @@ -510,7 +510,7 @@ } }; -Sprite.prototype.setTexture = function () +Sprite.prototype.setTexture = function () { window.console.warn('setTexture is now deprecated, please use the texture property, e.g : sprite.texture = texture; '); }; diff --git a/src/extras/TilingSprite.js b/src/extras/TilingSprite.js index ff34740..a8bb4f5 100644 --- a/src/extras/TilingSprite.js +++ b/src/extras/TilingSprite.js @@ -445,7 +445,7 @@ * Checks if a point is inside this tiling sprite * @param point {Point} the point to check */ -TilingSprite.prototype.hitTest = function( point ) +TilingSprite.prototype.containsPoint = function( point ) { this.worldTransform.applyInverse(point, tempPoint); diff --git a/src/interaction/InteractionManager.js b/src/interaction/InteractionManager.js index 936909b..2a6e8d9 100644 --- a/src/interaction/InteractionManager.js +++ b/src/interaction/InteractionManager.js @@ -361,9 +361,9 @@ displayObject.worldTransform.applyInverse(point, this._tempPoint); hit = displayObject.hitArea.contains( this._tempPoint.x, this._tempPoint.y ); } - else if(displayObject.hitTest) + else if(displayObject.containsPoint) { - hit = displayObject.hitTest(point); + hit = displayObject.containsPoint(point); } } @@ -725,7 +725,7 @@ /** * Grabs an interaction data object from the internal pool - * + * * @param touchEvent {EventData} The touch event we need to pair with an interactionData object * * @private diff --git a/src/core/sprites/Sprite.js b/src/core/sprites/Sprite.js index 626c920..fa4fff6 100644 --- a/src/core/sprites/Sprite.js +++ b/src/core/sprites/Sprite.js @@ -510,7 +510,7 @@ } }; -Sprite.prototype.setTexture = function () +Sprite.prototype.setTexture = function () { window.console.warn('setTexture is now deprecated, please use the texture property, e.g : sprite.texture = texture; '); }; diff --git a/src/extras/TilingSprite.js b/src/extras/TilingSprite.js index ff34740..a8bb4f5 100644 --- a/src/extras/TilingSprite.js +++ b/src/extras/TilingSprite.js @@ -445,7 +445,7 @@ * Checks if a point is inside this tiling sprite * @param point {Point} the point to check */ -TilingSprite.prototype.hitTest = function( point ) +TilingSprite.prototype.containsPoint = function( point ) { this.worldTransform.applyInverse(point, tempPoint); diff --git a/src/interaction/InteractionManager.js b/src/interaction/InteractionManager.js index 936909b..2a6e8d9 100644 --- a/src/interaction/InteractionManager.js +++ b/src/interaction/InteractionManager.js @@ -361,9 +361,9 @@ displayObject.worldTransform.applyInverse(point, this._tempPoint); hit = displayObject.hitArea.contains( this._tempPoint.x, this._tempPoint.y ); } - else if(displayObject.hitTest) + else if(displayObject.containsPoint) { - hit = displayObject.hitTest(point); + hit = displayObject.containsPoint(point); } } @@ -725,7 +725,7 @@ /** * Grabs an interaction data object from the internal pool - * + * * @param touchEvent {EventData} The touch event we need to pair with an interactionData object * * @private diff --git a/src/interaction/interactiveTarget.js b/src/interaction/interactiveTarget.js index 96c57f0..a7f2ae5 100644 --- a/src/interaction/interactiveTarget.js +++ b/src/interaction/interactiveTarget.js @@ -10,10 +10,4 @@ core.DisplayObject.prototype._over = false; core.DisplayObject.prototype._touchDown = false; - -core.Sprite.prototype.hitTest = core.Sprite.prototype.containsPoint; - - -core.Graphics.prototype.hitTest = core.Graphics.prototype.containsPoint; - module.exports = {};