You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+17-9Lines changed: 17 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,13 +4,23 @@
4
4
5
5
### Input System Changes
6
6
7
+
#### Input System Bug Fixes
8
+
9
+
* Calling `setPollAlways()` would cause the `'pointerdown'` event to fire multiple times. Fix #4541 (thanks @Neyromantik)
10
+
* The pointer events were intermittently not registered, causing `pointerup` to often fail. Fix #4538 (thanks @paulsymphony)
11
+
* Due to a regression in 3.16 the drag events were not performing as fast as before, causing drags to feel lagged. Fix #4500 (thanks @aliblong)
12
+
* Over and Out events now work for any number of pointers in multi-touch environments, not just the first touch pointer registered. They also now fire correctly on touch start and touch end / cancel events.
13
+
14
+
#### Input System API Changes
15
+
7
16
The old 'input queue' legacy system, which was deprecated in 3.16, has been removed entirely in order to tidy-up the API and keep input events consistent. This means the following changes:
8
17
9
18
* Removed the `inputQueue` Game config property.
10
19
* Removed the `useQueue`, `queue` and `_updatedThisFrame` properties from the Input Manager.
11
20
* Removed the `legacyUpdate` and `update` methods from the Input Manager.
12
21
* Removed the `ignoreEvents` property as this should now be handled on a per-event basis.
13
22
* The Input Manager no longer listens for the `GameEvents.POST_STEP` event.
23
+
* The following Input Manager methods no longer require the `time` argument, as it's taken from the event timeStamp: `startPointer`, `updatePointer`, `stopPointer` and `cancelPointer`. All of these methods also now calculate the pointer motion updates.
14
24
15
25
As a result, all of the following Input Manager methods have been renamed:
16
26
@@ -22,7 +32,7 @@ As a result, all of the following Input Manager methods have been renamed:
22
32
*`queueMouseMove` is now called `onMouseMove` and invoked by the Mouse Manager.
23
33
*`queueMouseUp` is now called `onMouseUp` and invoked by the Mouse Manager.
24
34
25
-
Each of these handlers used to check the `enabled` state of the Input Manager, but this now handled directly in the Touch and Mouse Managers instead, leading to less branching and cleaner tests.
35
+
Each of these handlers used to check the `enabled` state of the Input Manager, but this now handled directly in the Touch and Mouse Managers instead, leading to less branching and cleaner tests. They also all used to run an IIFE that updated motion on the changed pointers array, but this is now handled directly in the event handler, allowing it to be removed from here.
26
36
27
37
Because the legacy queue mode is gone, there is no longer any need for the DOM Callbacks:
28
38
@@ -41,6 +51,8 @@ The following changes took place in the Input Plugin class:
41
51
*`processDragUpEvent` is a new method that handles an up event for drag enabled Game Objects.
42
52
*`processDragStartList` is a new internal method that builds a drag list for a pointer.
43
53
*`processDragThresholdEvent` is a new internal method that tests when a pointer with drag thresholds can drag.
54
+
*`processOverEvents` is a new internal method that handles when a touch pointer starts and checks for over events.
55
+
*`processOutEvents` is a new internal method that handles when a touch pointer stops and checks for out events.
44
56
45
57
The following changes took place in the Pointer class:
46
58
@@ -49,14 +61,10 @@ The following changes took place in the Pointer class:
49
61
*`Pointer.justUp` has been removed as it's not used internally and makes no sense under the DOM event system.
50
62
*`Pointer.justMoved` has been removed as it's not used internally and makes no sense under the DOM event system.
51
63
* The `Pointer.reset` method has been removed as it's no longer required internally.
52
-
53
-
#### Input System Bug Fixes
54
-
55
-
* Calling `setPollAlways()` would cause the `'pointerdown'` event to fire multiple times. Fix #4541 (thanks @Neyromantik)
56
-
* The pointer events were intermittently not registered, causing `pointerup` to often fail. Fix #4538 (thanks @paulsymphony)
57
-
* Due to a regression in 3.16 the drag events were not performing as fast as before, causing drags to feel lagged. Fix #4500 (thanks @aliblong)
58
-
* Over and Out events should now work for any pointer in multi-touch environments, not just the first touch pointer registered.
59
-
64
+
*`Pointer.touchstart` now has two arguments, the Touch List entry and the Touch Event. The full Touch Event is now stored in `Pointer.event` (instead of the Touch List entry).
65
+
*`Pointer.touchmove` now has two arguments, the Touch List entry and the Touch Event. The full Touch Event is now stored in `Pointer.event` (instead of the Touch List entry).
66
+
*`Pointer.touchend` now has two arguments, the Touch List entry and the Touch Event. The full Touch Event is now stored in `Pointer.event` (instead of the Touch List entry).
67
+
*`Pointer.touchcancel` now has two arguments, the Touch List entry and the Touch Event. The full Touch Event is now stored in `Pointer.event` (instead of the Touch List entry).
0 commit comments