From 7f2dd1d49cc3c0bf5e24fdb37f6457151c1f06c4 Mon Sep 17 00:00:00 2001 From: Saad Najmi Date: Sun, 5 Feb 2023 06:49:08 -0800 Subject: [PATCH] Pull out CGContext early in UIImage+Diff (#35940) Summary: This is a small refactor designed to make future merges for React Native macOS easier. It was found while merging React Native 0.71 into React Native macOS. In React Native macOS, we ifdef iOS out API's and replace them with macOS APIs, reusing as much code as possible. `CGContext` is a type that is available on both iOS and macOS, but `UIGraphicsImageRendererContext` is not. A simple refactor makes it easier to reuse this code in React Native macOS without affecting iOS :) Resolves https://github.com/microsoft/react-native-macos/issues/1676 ## Changelog