From f3078d6df6161a603ceb784c806736a3f6ab107d Mon Sep 17 00:00:00 2001 From: Liron Yahdav Date: Wed, 21 Jul 2021 11:10:50 -0700 Subject: [PATCH 1/3] Fix crash in Islands when opening Flyout without a target #6714 --- .../Flyout/FlyoutExample.windows.tsx | 35 +++++++++++++++++++ .../Views/FlyoutViewManager.cpp | 11 +++++- 2 files changed, 45 insertions(+), 1 deletion(-) diff --git a/packages/@react-native-windows/tester/src/js/examples-win/Flyout/FlyoutExample.windows.tsx b/packages/@react-native-windows/tester/src/js/examples-win/Flyout/FlyoutExample.windows.tsx index 1e866d635c0..fcc578758c3 100644 --- a/packages/@react-native-windows/tester/src/js/examples-win/Flyout/FlyoutExample.windows.tsx +++ b/packages/@react-native-windows/tester/src/js/examples-win/Flyout/FlyoutExample.windows.tsx @@ -10,9 +10,11 @@ import {Flyout, Picker, Popup, Placement} from 'react-native-windows'; interface IFlyoutExampleState { isFlyoutVisible: boolean; + isFlyoutNoTargetVisible: boolean; isFlyoutTwoVisible: boolean; isPopupVisible: boolean; buttonTitle: string; + buttonNoTargetTitle: string; isLightDismissEnabled: boolean; isOverlayEnabled: boolean; popupSwitchState: boolean; @@ -41,9 +43,11 @@ class FlyoutExample extends React.Component<{}, IFlyoutExampleState> { public state: IFlyoutExampleState = { isFlyoutVisible: false, + isFlyoutNoTargetVisible: false, isFlyoutTwoVisible: false, isPopupVisible: false, buttonTitle: 'Open Flyout', + buttonNoTargetTitle: 'Open Flyout without Target', isLightDismissEnabled: true, isOverlayEnabled: false, popupSwitchState: true, @@ -76,6 +80,12 @@ class FlyoutExample extends React.Component<{}, IFlyoutExampleState> {