Skip to content

Commit e92a019

Browse files
committed
If you destroyed a Game Object that had a custom cursor set during one of its input events the cursor didn't correctly reset. Fix phaserjs#4033
1 parent 78874b6 commit e92a019

2 files changed

Lines changed: 3 additions & 0 deletions

File tree

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,7 @@ Doing this gives you the ability to modify the texture before this happens, allo
106106
* The WebGL Renderer now always enables the `SCISSOR_TEST`, this allows Game Objects that use the scissor (such as custom objects, or Bitmap Text) to render properly again.
107107
* The Cameras `setScene` method, which is called automatically when a new Camera is created, will now call `updateSystem` which correctly increases the custom viewport counter. This fixes an issue with mini-cams inside of larger cameras not clipping their contents properly. If a Camera is moved to another Scene it also now correctly shrinks the total custom viewport counter.
108108
* Due to the two fixes above another bug was fixed: The ability for you to swap between Cameras with and without `setRenderToTexture` enabled with custom shaders. Previously if you used this with a custom shader then only the first Camera using the shader would render, the rest would appear black. Now, all Cameras using the custom shader work correctly. As a result all of the 'experimental' Camera rendering properties from 3.12 have been moved to stable.
109+
* If you destroyed a Game Object that had a custom cursor set during one of its input events the cursor didn't correctly reset. Fix #4033 (thanks @pantoninho)
109110

110111
### Examples, Documentation and TypeScript
111112

src/input/InputPlugin.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -595,6 +595,8 @@ var InputPlugin = new Class({
595595
input.hitAreaCallback = undefined;
596596
input.callbackContext = undefined;
597597

598+
this.manager.resetCursor(input);
599+
598600
gameObject.input = null;
599601

600602
// Clear from _draggable, _drag and _over

0 commit comments

Comments
 (0)