Пример #1
0
 protected virtual void OnLayout(object sender, Native.LayoutEventArgs e)
 {
     RealControl.Geometry = Control.Geometry;
     if (_backgroundCanvas.IsValueCreated)
     {
         BackgroundCanvas.Geometry = Control.Geometry;
     }
 }
Пример #2
0
 protected override void OnBackgroundLayoutUpdated(object sender, Native.LayoutEventArgs e)
 {
     base.OnBackgroundLayoutUpdated(sender, e);
     if (_cliper != null)
     {
         _cliper.Geometry = Control.Geometry;
         if (Element.Content != null)
         {
             var nativeView = Platform.GetOrCreateRenderer(Element.Content)?.NativeView;
             nativeView?.SetClip(null);
             nativeView?.SetClip(_cliper);
         }
     }
 }
Пример #3
0
 protected override void OnBackgroundLayoutUpdated(object sender, Native.LayoutEventArgs e)
 {
     base.OnBackgroundLayoutUpdated(sender, e);
     _clipper.Geometry = Control.Geometry;
     _clipper.Invalidate();
 }