From 0072cd642dd0eabfcf5493f1d173631ce91d57ca Mon Sep 17 00:00:00 2001 From: Andrew <30809111+acoates-ms@users.noreply.github.com> Date: Tue, 9 Jul 2024 17:50:22 -0700 Subject: [PATCH 1/3] Add image response APIs to win32 exports --- vnext/Desktop/module.g.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/vnext/Desktop/module.g.cpp b/vnext/Desktop/module.g.cpp index 76aa0100486..f14f63909db 100644 --- a/vnext/Desktop/module.g.cpp +++ b/vnext/Desktop/module.g.cpp @@ -8,6 +8,9 @@ void* winrt_make_Microsoft_Internal_TestController(); void* winrt_make_Microsoft_ReactNative_ReactNativeIsland(); #ifdef USE_WINUI3 +void *winrt_make_Microsoft_ReactNative_Composition_ImageFailedResponse(); +void *winrt_make_Microsoft_ReactNative_Composition_StreamImageResponse(); +void *winrt_make_Microsoft_ReactNative_Composition_Experimental_UriBrushFactoryImageResponse(); void *winrt_make_Microsoft_ReactNative_Composition_Experimental_MicrosoftCompositionContextHelper(); #endif void *winrt_make_Microsoft_ReactNative_Composition_Experimental_SystemCompositionContextHelper(); @@ -65,6 +68,15 @@ void* __stdcall winrt_get_activation_factory([[maybe_unused]] std::wstring_view return winrt_make_Microsoft_ReactNative_ReactNativeIsland(); } #ifdef USE_WINUI3 + if (requal(name, L"Microsoft.ReactNative.Composition.ImageFailedResponse")) { + return winrt_make_Microsoft_ReactNative_Composition_ImageFailedResponse(); + } + if (requal(name, L"Microsoft.ReactNative.Composition.StreamImageResponse")) { + return winrt_make_Microsoft_ReactNative_Composition_StreamImageResponse(); + } + if (requal(name, L"Microsoft.ReactNative.Composition.Experimental.UriBrushFactoryImageResponse")) { + return winrt_make_Microsoft_ReactNative_Composition_Experimental_UriBrushFactoryImageResponse(); + } if (requal(name, L"Microsoft.ReactNative.Composition.Experimental.MicrosoftCompositionContextHelper")) { return winrt_make_Microsoft_ReactNative_Composition_Experimental_MicrosoftCompositionContextHelper(); } From a9b5c76508f5890df8b9a98456b57a6f0afa6c53 Mon Sep 17 00:00:00 2001 From: Andrew <30809111+acoates-ms@users.noreply.github.com> Date: Tue, 9 Jul 2024 17:50:29 -0700 Subject: [PATCH 2/3] Change files --- ...ative-windows-759b1fea-b751-4ff5-8448-61302a4756e5.json | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 change/react-native-windows-759b1fea-b751-4ff5-8448-61302a4756e5.json diff --git a/change/react-native-windows-759b1fea-b751-4ff5-8448-61302a4756e5.json b/change/react-native-windows-759b1fea-b751-4ff5-8448-61302a4756e5.json new file mode 100644 index 00000000000..7e6dca05b08 --- /dev/null +++ b/change/react-native-windows-759b1fea-b751-4ff5-8448-61302a4756e5.json @@ -0,0 +1,7 @@ +{ + "type": "prerelease", + "comment": "Add image response APIs to win32 exports", + "packageName": "react-native-windows", + "email": "30809111+acoates-ms@users.noreply.github.com", + "dependentChangeType": "patch" +} From dd994baf0d054dcc7b9af8f56592155665d2e749 Mon Sep 17 00:00:00 2001 From: Andrew <30809111+acoates-ms@users.noreply.github.com> Date: Wed, 10 Jul 2024 07:07:31 -0700 Subject: [PATCH 3/3] fix --- vnext/Desktop/module.g.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/vnext/Desktop/module.g.cpp b/vnext/Desktop/module.g.cpp index f14f63909db..3762ad99669 100644 --- a/vnext/Desktop/module.g.cpp +++ b/vnext/Desktop/module.g.cpp @@ -31,6 +31,15 @@ void* winrt_make_facebook_react_NativeLogEventSource(); void* winrt_make_facebook_react_NativeTraceEventSource(); #ifndef USE_FABRIC +void *winrt_make_Microsoft_ReactNative_Composition_ImageFailedResponse() { + winrt::throw_hresult(E_NOTIMPL); +} +void *winrt_make_Microsoft_ReactNative_Composition_StreamImageResponse() { + winrt::throw_hresult(E_NOTIMPL); +} +void *winrt_make_Microsoft_ReactNative_Composition_Experimental_UriBrushFactoryImageResponse() { + winrt::throw_hresult(E_NOTIMPL); +} void* winrt_make_Microsoft_ReactNative_ReactNativeIsland() { winrt::throw_hresult(E_NOTIMPL); }