Ejemplo n.º 1
0
		public PieceViewController GetPage(int i)
		{
			var coll = Series;
			var piece = coll.Pieces[i];
			
			RectangleF canvasFrame;
			var imageView = ImageFactory.BuildGalleryPage(piece, i, coll.Pieces.Count, out canvasFrame);
			imageView.ClipsToBounds = false;
							
			PieceViewController pvc = new PieceViewController(piece, canvasFrame, _parent, imageView);
			pvc.View.Frame = imageView.Frame;
			pvc.View.AddSubview(imageView);
			pvc.View.ClipsToBounds = false;
			
			RectangleF frame = GetGalleryDimensions();
			imageView.Bounds = frame;
			imageView.Frame = frame;
						
			return pvc;
		}
Ejemplo n.º 2
0
        private void SetPageFrame(PieceViewController pvc, int i)
        {
            RectangleF frame;

            if (Util.IsPortrait())
            {
                frame = new RectangleF(
                    DimensionSet.ScreenWidth * i, 0,
                    DimensionSet.ScreenWidth, GalleryScreenHeight
                    );
            }
            else
            {
                frame = new RectangleF(
                    UIScreen.MainScreen.Bounds.Height * i, 0,
                    UIScreen.MainScreen.Bounds.Height, UIScreen.MainScreen.Bounds.Width
                    );
            }
            pvc.View.Frame = frame;
        }
Ejemplo n.º 3
0
        public PieceViewController GetPage(int i)
        {
            var coll  = Series;
            var piece = coll.Pieces[i];

            RectangleF canvasFrame;
            var        imageView = ImageFactory.BuildGalleryPage(piece, i, coll.Pieces.Count, out canvasFrame);

            imageView.ClipsToBounds = false;

            PieceViewController pvc = new PieceViewController(piece, canvasFrame, _parent, imageView);

            pvc.View.Frame = imageView.Frame;
            pvc.View.AddSubview(imageView);
            pvc.View.ClipsToBounds = false;

            RectangleF frame = GetGalleryDimensions();

            imageView.Bounds = frame;
            imageView.Frame  = frame;

            return(pvc);
        }
Ejemplo n.º 4
0
		private void SetPageFrame(PieceViewController pvc, int i)
		{
			RectangleF frame;
			if(Util.IsPortrait())
			{
				frame = new RectangleF(
					DimensionSet.ScreenWidth * i, 0, 
					DimensionSet.ScreenWidth, GalleryScreenHeight
				);
			}
			else
			{
				frame = new RectangleF(
					UIScreen.MainScreen.Bounds.Height * i, 0, 
					UIScreen.MainScreen.Bounds.Height, UIScreen.MainScreen.Bounds.Width
					);
			}				
			pvc.View.Frame = frame;
		}