I'm having some problems with the zoomscale on my scrollview in landscape mode. I want my image to scale perfectly when i put my iphone in landscape. I have the zoomscale on my scrollview working fine when i'm loading my image in portrait mode, but when i put it to landscape, it wont change the scale, unless I go back to the tableview and put the iphone in landscape, and then load the image.
Any help apriciated!
I've tried using such as:
if (UIDeviceOrientationIsLandscape(UIDevice .currentDevice().orientation))
{
scrollView.zoomScale = 0.50
}
if (UIDeviceOrientationIsPortrait(UIDevice .currentDevice().orientation))
{
scrollView.zoomScale = 0.25
}
This is how it looks like when I load the image in portrait mode:
This is how it looks like when i rotate the iphone from portrait mode while having the picture open(I want it to be as the image below):
This is how it looks like when i load the image in landscape mode:



UIDevice.currentDevice(). beginGeneratingDeviceOrientationNotifications()etc. - Juri Noga