Skip to content

Conversation

shwanton
Copy link

@shwanton shwanton commented Jan 24, 2023

Please select one of the following

  • I am removing an existing difference between facebook/react-native and microsoft/react-native-macos 👍
  • I am cherry-picking a change from Facebook's react-native into microsoft/react-native-macos 👍
  • I am making a fix / change for the macOS implementation of react-native
  • I am making a change required for Microsoft usage of react-native

Summary

Fabric on macOS implementation:
Shim RCTSurfaceTouchHandler to work w/ Fabric

closes #1542
closes #1572

Changelog

[macOS][Added] - Shim RCTSurfaceTouchHandler for Fabric

Test Plan

[x] Build RNTester-macOS w/ Fabric - doesn’t run yet, but no RCTSurfaceTouchHandler errors
CleanShot 2023-01-23 at 17 57 09

[x] Build RNTester - iOS w/ Fabric
CleanShot 2023-01-23 at 17 49 54

[x] Build RNTester-macOS w/ Paper - should work
CleanShot 2023-01-23 at 20 30 18

[x] Build RNTester - iOS w /Paper -
CleanShot 2023-01-23 at 20 32 34

@shwanton shwanton marked this pull request as ready for review January 24, 2023 04:41
@shwanton shwanton requested a review from a team as a code owner January 24, 2023 04:41
@shwanton shwanton changed the title Shim RCTSurfaceTouchHandler [Fabric] Shim RCTSurfaceTouchHandler Jan 24, 2023
Copy link
Collaborator

@Saadnajmi Saadnajmi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we decided this already, but for Fabric we still have to fake mouse clicks into touches?

Main comment is if possible, let's default to typedefs instead of #define for all new shims?

@shwanton
Copy link
Author

I think we decided this already, but for Fabric we still have to fake mouse clicks into touches?

Till we move to Pointer events, we will still need to convert clicks -> touches.

@Saadnajmi Saadnajmi merged commit d744e5a into microsoft:main Jan 24, 2023
@shwanton shwanton deleted the fabric/shim-rctsurfacetouchhandler branch January 24, 2023 23:43
shwanton added a commit to shwanton/react-native-macos that referenced this pull request Feb 13, 2023
* Shim RCTSurfaceTouchHandler

* Shim NSTouch in RCTUIKit

* Shim RCTUITouch -> NSEvent

* [Fabric] Fix RCTTouchEvent Shim

Co-authored-by: Shawn Dempsey <shawndempsey@fb.com>
shwanton added a commit to shwanton/react-native-macos that referenced this pull request Mar 10, 2023
* Shim RCTSurfaceTouchHandler

* Shim NSTouch in RCTUIKit

* Shim RCTUITouch -> NSEvent

* [Fabric] Fix RCTTouchEvent Shim

Co-authored-by: Shawn Dempsey <shawndempsey@fb.com>
# Conflicts:
#	React/Base/RCTUIKit.h
#	React/Fabric/RCTSurfaceTouchHandler.mm
shwanton added a commit to shwanton/react-native-macos that referenced this pull request Mar 10, 2023
* Shim RCTSurfaceTouchHandler

* Shim NSTouch in RCTUIKit

* Shim RCTUITouch -> NSEvent

* [Fabric] Fix RCTTouchEvent Shim

Co-authored-by: Shawn Dempsey <shawndempsey@fb.com>
# Conflicts:
#	React/Base/RCTUIKit.h
#	React/Fabric/RCTSurfaceTouchHandler.mm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

RCTSurfaceTouchHandler Shim RCTSurfaceTouchHandler

2 participants