Skip to content

Commit 58bd51e

Browse files
j-piaseckimeta-codesync[bot]
authored andcommitted
Increase the maximum number of pointers tracked at the same time on iOS to 17 (facebook#54248)
Summary: Pull Request resolved: facebook#54248 Changelog: [IOS][FIXED] - Raised the maximum number of pointers tracked at the same time to 17 The current pool of pointer ids that can be used at the same time has the size of 11, while the maximum supported by some of the devices is 17 - https://developer.apple.com/forums/thread/17606. To reproduce this problem use the iPad pro and place more than 11 pointers on the screen - the app becomes unresponsive due to [an infinite loop](https://github.com/facebook/react-native/blob/d93d32547bfadba731999ea251ca5e1d6c6c8912/packages/react-native/React/Fabric/Utils/RCTIdentifierPool.h#L22). Reviewed By: cipolleschi Differential Revision: D85345975 fbshipit-source-id: df6ba61f933406e7dc4e31382b35f002611fa433
1 parent fcb51b1 commit 58bd51e

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

packages/react-native/React/Fabric/RCTSurfacePointerHandler.mm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -437,7 +437,7 @@ @implementation RCTSurfacePointerHandler {
437437
* We hold the view weakly to prevent a retain cycle.
438438
*/
439439
__weak UIView *_rootComponentView;
440-
RCTIdentifierPool<11> _identifierPool;
440+
RCTIdentifierPool<17> _identifierPool;
441441

442442
UIHoverGestureRecognizer *_mouseHoverRecognizer API_AVAILABLE(ios(13.0));
443443
UIHoverGestureRecognizer *_penHoverRecognizer API_AVAILABLE(ios(13.0));

packages/react-native/React/Fabric/RCTSurfaceTouchHandler.mm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ @implementation RCTSurfaceTouchHandler {
137137
* We hold the view weakly to prevent a retain cycle.
138138
*/
139139
__weak UIView *_rootComponentView;
140-
RCTIdentifierPool<11> _identifierPool;
140+
RCTIdentifierPool<17> _identifierPool;
141141

142142
RCTSurfacePointerHandler *_pointerHandler;
143143
}

0 commit comments

Comments
 (0)