diff options
author | Jay Freeman <saurik@saurik.com> | 2009-08-14 12:23:08 +0000 |
---|---|---|
committer | Jay Freeman <saurik@saurik.com> | 2009-08-14 12:23:08 +0000 |
commit | 2bcf623a567c3f4507a6d781976a20b6d1531679 (patch) | |
tree | 173736fbc33b1c8ffc5377783619edc30fa0c3a1 /data/mobileterminal/orientation.diff | |
parent | 1ec7964f62c88a9fea608e439c75ce6d9586ccae (diff) |
Fixed the stupid bug where this app starts upside down.
git-svn-id: http://svn.telesphoreo.org/trunk@662 514c082c-b64e-11dc-b46d-3d985efe055d
Diffstat (limited to 'data/mobileterminal/orientation.diff')
-rw-r--r-- | data/mobileterminal/orientation.diff | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/data/mobileterminal/orientation.diff b/data/mobileterminal/orientation.diff new file mode 100644 index 000000000..07ce177d3 --- /dev/null +++ b/data/mobileterminal/orientation.diff @@ -0,0 +1,22 @@ +diff -ru mobileterminal-364/Sources/UI/MainViewController.m mobileterminal-364+iPhone/Sources/UI/MainViewController.m +--- mobileterminal-364/Sources/UI/MainViewController.m 2009-04-26 07:54:34.000000000 +0000 ++++ mobileterminal-364+iPhone/Sources/UI/MainViewController.m 2009-08-14 12:09:20.000000000 +0000 +@@ -265,6 +265,8 @@ + + - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)orientation + { ++ bool yes = targetOrientation_ == UIDeviceOrientationUnknown; ++ + int currentOrientation = [self interfaceOrientation]; + if (currentOrientation && currentOrientation != orientation) { + targetOrientation_ = orientation; +@@ -280,6 +282,9 @@ + [keyboardView setAlpha:0.0f]; + [self.activeTextView.tiledView setAlpha:0.0f]; + [UIView commitAnimations]; ++ } else if (yes) { ++ targetOrientation_ = orientation; ++ return YES; + } + + return NO; |