public override void LoadView() { var rect = UIScreen.MainScreen.Bounds; rect = CGAffineTransform.CGRectApplyAffineTransform (rect, CGAffineTransform.MakeRotation ((float)(90.0f * Math.PI / 180.0f))); rect.Location = PointF.Empty; this.View = new UIView (rect); this.View.BackgroundColor = UIColor.White; this.View.AutoresizingMask = UIViewAutoresizing.FlexibleWidth | UIViewAutoresizing.FlexibleHeight; rect = this.View.Bounds; rect.Height = 1000; _coverFlowDelegate = new CoverDelegate(); _coverFlowDataSource = new CoverDataSource(this); coverflow = new TKCoverflowView(this.View.Bounds); coverflow.AutoresizingMask = UIViewAutoresizing.FlexibleWidth | UIViewAutoresizing.FlexibleHeight; coverflow.CoverflowDelegate = _coverFlowDelegate; coverflow.DataSource = _coverFlowDataSource; if (UIDevice.CurrentDevice.UserInterfaceIdiom == UIUserInterfaceIdiom.Pad) { coverflow.CoverSpacing = 100; coverflow.CoverSize = new SizeF (300, 300); } this.View.AddSubview (coverflow); }
public override void LoadView() { var rect = UIScreen.MainScreen.Bounds; rect = CGAffineTransform.CGRectApplyAffineTransform(rect, CGAffineTransform.MakeRotation((float)(90.0f * Math.PI / 180.0f))); rect.Location = PointF.Empty; this.View = new UIView(rect); this.View.BackgroundColor = UIColor.White; this.View.AutoresizingMask = UIViewAutoresizing.FlexibleWidth | UIViewAutoresizing.FlexibleHeight; rect = this.View.Bounds; rect.Height = 1000; _coverFlowDelegate = new CoverDelegate(); _coverFlowDataSource = new CoverDataSource(this); coverflow = new TKCoverflowView(this.View.Bounds); coverflow.AutoresizingMask = UIViewAutoresizing.FlexibleWidth | UIViewAutoresizing.FlexibleHeight; coverflow.CoverflowDelegate = _coverFlowDelegate; coverflow.DataSource = _coverFlowDataSource; if (UIDevice.CurrentDevice.UserInterfaceIdiom == UIUserInterfaceIdiom.Pad) { coverflow.CoverSpacing = 100; coverflow.CoverSize = new SizeF(300, 300); } this.View.AddSubview(coverflow); }