protected override void OnSizeChanged(int w, int h, int oldw, int oldh)
        {
            base.OnSizeChanged(w, h, oldw, oldh);

            Renderer.Element.Layout(new Rectangle(0.0, 0.0, ContextExtensions.FromPixels(Context, w), ContextExtensions.FromPixels(Context, h)));
            Renderer.UpdateLayout();
        }
 protected override void OnLayout(bool changed, int left, int top, int right, int bottom)
 {
     if (Renderer == null)
     {
         return;
     }
     Renderer.Element.Layout(new Rectangle(0.0, 0.0, ContextExtensions.FromPixels(Context, right - left), ContextExtensions.FromPixels(Context, bottom - top)));
     Renderer.UpdateLayout();
 }
Exemplo n.º 3
0
 private double FromPixels(int value)
 {
     return(ContextExtensions.FromPixels(Forms.Context, value));
 }