cocos2d/cocos2d-iphone — pull request #251 by dangero (2012-10-21 20:10:24+00:00)
Title: Adding support for rotations on iOS 6. We need access to will rotate not...

willRotateToInterfaceOrientation should be passed onto the delegate because that allows the developer to move things around in the cocos2d scene if the aspect ratio has changed. (If the app supports both portrait and landscape)

willRotateToInterfaceOrientation is called on all versions of iOS including iOS 6 when a rotation will occur, so it creates the perfect place to handle interface orientations in your app.

Using UIDeviceOrientationDidChangeNotification to get notification on your scene is not a reasonable solution because device orientations are different than interface orientations, for example, UIDeviceOrientationFaceUp is a device orientation, but not an interface orientation.