From 76bca800b6809e44bcf33b6e94d7a7ac54a7c6e8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oskar=20Kwas=CC=81niewski?= Date: Fri, 2 Feb 2024 13:29:14 +0100 Subject: [PATCH] fix: add typecast --- apple/LayoutReanimation/REAAnimationsManager.m | 2 +- apple/LayoutReanimation/REASharedTransitionManager.m | 2 +- apple/LayoutReanimation/REASnapshot.m | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/apple/LayoutReanimation/REAAnimationsManager.m b/apple/LayoutReanimation/REAAnimationsManager.m index e81f8ebe334e..7eca632333a7 100644 --- a/apple/LayoutReanimation/REAAnimationsManager.m +++ b/apple/LayoutReanimation/REAAnimationsManager.m @@ -250,7 +250,7 @@ - (void)setNewProps:(NSMutableDictionary *)newProps if (needsViewPositionUpdate) { CGPoint newCenter = CGPointMake(centerX, centerY); if (convertFromAbsolute) { - REAUIView *window = RCTKeyWindow(); + REAUIView *window = (REAUIView* )RCTKeyWindow(); CGPoint convertedCenter = [window convertPoint:newCenter toView:view.superview]; view.center = convertedCenter; } else { diff --git a/apple/LayoutReanimation/REASharedTransitionManager.m b/apple/LayoutReanimation/REASharedTransitionManager.m index ecda9932f839..fce3f39d4721 100644 --- a/apple/LayoutReanimation/REASharedTransitionManager.m +++ b/apple/LayoutReanimation/REASharedTransitionManager.m @@ -529,7 +529,7 @@ - (void)configureTransitionContainer { if (!_isSharedTransitionActive) { _isSharedTransitionActive = YES; - REAUIView *mainWindow = RCTKeyWindow(); + REAUIView *mainWindow = (REAUIView* )RCTKeyWindow(); if (_transitionContainer == nil) { _transitionContainer = [REAUIView new]; } diff --git a/apple/LayoutReanimation/REASnapshot.m b/apple/LayoutReanimation/REASnapshot.m index 51df531faca0..d7cf1ddbffee 100644 --- a/apple/LayoutReanimation/REASnapshot.m +++ b/apple/LayoutReanimation/REASnapshot.m @@ -28,7 +28,7 @@ - (instancetype)initWithAbsolutePosition:(REAUIView *)view - (void)makeSnapshotForView:(REAUIView *)view useAbsolutePositionOnly:(BOOL)useAbsolutePositionOnly { - REAUIView *mainWindow = RCTKeyWindow(); + REAUIView *mainWindow = (REAUIView* )RCTKeyWindow(); CGPoint absolutePosition = [[view superview] convertPoint:view.center toView:nil]; _values = [NSMutableDictionary new]; #if TARGET_OS_OSX