public override void LayoutChanged() { base.LayoutChanged(); float viewRealHeight = (float)(View.Bounds.Height - Task.NavToolbar.Frame.Height); float cardSizePerc = .83f; float cardWidth = (float)(View.Bounds.Width * cardSizePerc); float cardHeight = (float)(viewRealHeight * cardSizePerc); float cardYOffset = (viewRealHeight * .03f); // setup the card positions to be to the offscreen to the left, centered on screen, and offscreen to the right Carousel.LayoutChanged(cardWidth, cardHeight, new System.Drawing.RectangleF(0, cardYOffset, (float)View.Bounds.Width, viewRealHeight)); CardSize = new CGRect(0, 0, cardWidth, cardHeight); for (int i = 0; i < PrayerRequests.Count; i++) { PrayerRequests[i].LayoutChanged(CardSize.ToRectF( )); } BlockerView.SetBounds(View.Bounds.ToRectF( )); ResultView.SetBounds(View.Bounds.ToRectF( )); }
public override void LayoutChanged() { base.LayoutChanged(); float viewRealHeight = (float)( View.Bounds.Height - Task.NavToolbar.Frame.Height); float cardSizePerc = .83f; float cardWidth = (float)(View.Bounds.Width * cardSizePerc); float cardHeight = (float) (viewRealHeight * cardSizePerc); float cardYOffset = ( viewRealHeight * .03f ); // setup the card positions to be to the offscreen to the left, centered on screen, and offscreen to the right Carousel.LayoutChanged( cardWidth, cardHeight, new System.Drawing.RectangleF( 0, cardYOffset, (float)View.Bounds.Width, viewRealHeight ) ); CardSize = new CGRect( 0, 0, cardWidth, cardHeight ); for( int i = 0; i < PrayerRequests.Count; i++ ) { PrayerRequests[ i ].LayoutChanged( CardSize.ToRectF( ) ); } BlockerView.SetBounds( View.Bounds.ToRectF( ) ); }