Nimbus フレームワークのNIPhotoAlbumScrollViewを使用して いますが、デバイスを回転させると、表示される画像の中心位置が失われます... 誰かがこのコンポーネントを使用して、同じ状況に直面しましたか?
ps: NIPhotoAlbumScrollViewとそのNIPagingScrollViewPageの両方に(UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight)マスクを使用しています
Nimbus フレームワークのNIPhotoAlbumScrollViewを使用して いますが、デバイスを回転させると、表示される画像の中心位置が失われます... 誰かがこのコンポーネントを使用して、同じ状況に直面しましたか?
ps: NIPhotoAlbumScrollViewとそのNIPagingScrollViewPageの両方に(UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight)マスクを使用しています
対応するViewControllerメソッドでNIPhotoAlbumScrollViewのこれらのメソッドを呼び出します
- willRotateToInterfaceOrientation:duration:
- willAnimateRotationToInterfaceOrientation:duration:
このような
- (BOOL) shouldAutorotateToInterfaceOrientation: (UIInterfaceOrientation) toInterfaceOrientation { return YES; }
//====================================================================================================
- (void) willRotateToInterfaceOrientation: (UIInterfaceOrientation) toInterfaceOrientation duration: (NSTimeInterval) duration
{
[super willRotateToInterfaceOrientation: toInterfaceOrientation duration: duration];
[self.photoAlbumView willRotateToInterfaceOrientation: toInterfaceOrientation duration: duration];
}
//====================================================================================================
- (void) willAnimateRotationToInterfaceOrientation: (UIInterfaceOrientation) interfaceOrientation
duration: (NSTimeInterval) duration
{
[super willAnimateRotationToInterfaceOrientation: interfaceOrientation duration: duration];
[self.photoAlbumView willAnimateRotationToInterfaceOrientation: interfaceOrientation duration: duration];
}