diff options
Diffstat (limited to 'Xamarin.Forms.Platform.Android')
-rw-r--r-- | Xamarin.Forms.Platform.Android/NativeViewWrapperRenderer.cs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Xamarin.Forms.Platform.Android/NativeViewWrapperRenderer.cs b/Xamarin.Forms.Platform.Android/NativeViewWrapperRenderer.cs index 49abc02a..2036e4bb 100644 --- a/Xamarin.Forms.Platform.Android/NativeViewWrapperRenderer.cs +++ b/Xamarin.Forms.Platform.Android/NativeViewWrapperRenderer.cs @@ -1,3 +1,5 @@ +using Xamarin.Forms.Internals; + namespace Xamarin.Forms.Platform.Android { public class NativeViewWrapperRenderer : ViewRenderer<NativeViewWrapper, global::Android.Views.View> @@ -22,7 +24,7 @@ namespace Xamarin.Forms.Platform.Android if (e.OldElement == null) { SetNativeControl(Element.NativeView); - Control.LayoutChange += (sender, args) => Element?.InvalidateMeasure(InvalidationTrigger.MeasureChanged); + Control.LayoutChange += (sender, args) => ((IVisualElementController)Element)?.InvalidateMeasure(InvalidationTrigger.MeasureChanged); } } |