From 4b545f63b717150af354bca32e8b5a1ed47c26dd Mon Sep 17 00:00:00 2001 From: David Oliver Date: Thu, 13 May 2021 11:34:41 -0400 Subject: [PATCH] chore: Fix net461 and netstdref builds --- src/Uno.UI/UI/Xaml/FrameworkElement.net.cs | 2 ++ src/Uno.UI/UI/Xaml/FrameworkElement.netstdref.cs | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/Uno.UI/UI/Xaml/FrameworkElement.net.cs b/src/Uno.UI/UI/Xaml/FrameworkElement.net.cs index 3badae336f0c..fdcf0bc2b800 100644 --- a/src/Uno.UI/UI/Xaml/FrameworkElement.net.cs +++ b/src/Uno.UI/UI/Xaml/FrameworkElement.net.cs @@ -15,6 +15,8 @@ public partial class FrameworkElement : IEnumerable internal List _children = new List(); + internal UIElement VisualParent => ((IDependencyObjectStoreProvider)this).Store.Parent as UIElement; + private protected virtual void OnPostLoading() { } partial void OnLoadingPartial(); diff --git a/src/Uno.UI/UI/Xaml/FrameworkElement.netstdref.cs b/src/Uno.UI/UI/Xaml/FrameworkElement.netstdref.cs index 505f6a017dda..43d73cf5539a 100644 --- a/src/Uno.UI/UI/Xaml/FrameworkElement.netstdref.cs +++ b/src/Uno.UI/UI/Xaml/FrameworkElement.netstdref.cs @@ -12,6 +12,8 @@ public partial class FrameworkElement : IEnumerable { bool IFrameworkElementInternal.HasLayouter => throw new NotSupportedException("Reference assembly"); + internal UIElement VisualParent => throw new NotSupportedException("Reference assembly"); + internal T AddChild(T child) where T : View => throw new NotSupportedException("Reference assembly"); internal T AddChild(T child, int index) where T : View => throw new NotSupportedException("Reference assembly");