예제 #1
0
        float GetZoomValueToFit()
        {
            CGSize imageSize = mImage.Size;

            return(ImageDiffExtensions.CalculateZoomToFit(
                       imageSize.Width, imageSize.Height,
                       ContentSize.Width, ContentSize.Height));
        }
예제 #2
0
        void InitZoom()
        {
            if (ImageDiffExtensions.IsImageBiggerThanFrame(Frame.Size, mImage.Size))
            {
                ZoomLevel = GetZoomValueToFit();
                return;
            }

            ZoomLevel = 1;
        }