On Apr 22, 2010, at 8:35 AM, Joshua Garnham wrote: > My App runs in landscape mode and I have been converting a CGPoint > to the main UIWindow's co-ordinate system.
Why? There should generally be no need to convert to the window's coordinate system. > UIWindow's co-ordinate system the co-ordinates changed as if the iPhone was > in portrait mode. Thats because the window itself doesn't actually change coordinate systems, it applies a transform to its subviews that changes their coordinate system. > Code and Debugger results are as follows. > - > (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation > { > [[UIApplication sharedApplication] setStatusBarOrientation: > UIInterfaceOrientationLandscapeLeft]; > return (interfaceOrientation == UIInterfaceOrientationLandscapeLeft); > } Also note that you should not be changing the status bar orientation here. It is sufficient to simply return YES for the orientations that you want (assuming that you've done everything else correctly). -- David Duncan Apple DTS Animation and Printing _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com