<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -46,7 +46,7 @@ Three20 is compiled as a static library, and the easiest way to add it to your p
    it.  Add the relative path from your project's directory to the &quot;three20/src&quot; directory.
 
 8. While you are in Project Settings, go to &quot;Other Linker Flags&quot; under the &quot;Linker&quot; section, and
-   add &quot;-ObjC&quot; to the list of flags.
+   add &quot;-ObjC&quot; and &quot;-all_load&quot; to the list of flags.
 
 9. You're ready to go.  Just #import &quot;Three20/Three20.h&quot; anywhere you want to use Three20 classes
    in your project.</diff>
      <filename>README.mdown</filename>
    </modified>
    <modified>
      <diff>@@ -388,6 +388,10 @@
 				GCC_PREFIX_HEADER = TTCatalog_Prefix.pch;
 				GCC_PREPROCESSOR_DEFINITIONS = DEBUG;
 				INFOPLIST_FILE = Info.plist;
+				OTHER_LDFLAGS = (
+					&quot;-all_load&quot;,
+					&quot;-ObjC&quot;,
+				);
 				PRODUCT_NAME = TTCatalog;
 			};
 			name = Debug;
@@ -400,6 +404,10 @@
 				GCC_PRECOMPILE_PREFIX_HEADER = YES;
 				GCC_PREFIX_HEADER = TTCatalog_Prefix.pch;
 				INFOPLIST_FILE = Info.plist;
+				OTHER_LDFLAGS = (
+					&quot;-all_load&quot;,
+					&quot;-ObjC&quot;,
+				);
 				PRODUCT_NAME = TTCatalog;
 			};
 			name = Release;</diff>
      <filename>samples/TTCatalog/TTCatalog.xcodeproj/project.pbxproj</filename>
    </modified>
    <modified>
      <diff>@@ -8,7 +8,11 @@
   NSDateFormatter* formatter = [[[NSDateFormatter alloc] init] autorelease];
   formatter.dateFormat = @&quot;yyyy-d-M&quot;;
   
+#ifdef JOE
+  NSString* time = [formatter stringFromDate:[NSDate dateWithTimeIntervalSinceNow:-(60*60*24*14)]];
+# else
   NSString* time = [formatter stringFromDate:[NSDate date]];
+#endif  
   NSDate* date = [formatter dateFromString:time];
   return date;
 }</diff>
      <filename>src/NSDateAdditions.m</filename>
    </modified>
    <modified>
      <diff>@@ -89,6 +89,10 @@ void TTNetworkRequestStopped() {
   }
 }
 
+float TTOSVersion() {
+  return [[[UIDevice currentDevice] systemVersion] floatValue];
+}
+
 NSLocale* TTCurrentLocale() {
   NSUserDefaults* defaults = [NSUserDefaults standardUserDefaults];
   NSArray* languages = [defaults objectForKey:@&quot;AppleLanguages&quot;];</diff>
      <filename>src/TTGlobal.m</filename>
    </modified>
    <modified>
      <diff>@@ -326,7 +326,11 @@
 
   CGRect innerFrame = CGRectMake(0, TOOLBAR_HEIGHT,
     appFrame.size.width, appFrame.size.height - (TOOLBAR_HEIGHT+KEYBOARD_HEIGHT));
-  _scrollView = [[TTComposeInnerScrollView alloc] initWithFrame:innerFrame];
+  if (TTOSVersion() &gt;= 3.0) {
+    _scrollView = [[[UIScrollView class] alloc] initWithFrame:innerFrame];
+  } else {
+    _scrollView = [[[TTComposeInnerScrollView class] alloc] initWithFrame:innerFrame];
+  }
   _scrollView.backgroundColor = TTSTYLEVAR(backgroundColor);
   _scrollView.canCancelContentTouches = NO;
   _scrollView.showsVerticalScrollIndicator = NO;</diff>
      <filename>src/TTMessageController.m</filename>
    </modified>
    <modified>
      <diff>@@ -42,6 +42,10 @@ static const NSTimeInterval kSlideshowInterval = 2;
     self.navigationBarStyle = UIBarStyleBlackTranslucent;
     self.navigationBarTintColor = nil;
     self.statusBarStyle = UIStatusBarStyleBlackTranslucent;
+    
+    if (TTOSVersion() &gt;= 3.0) {
+      [self setWantsFullScreenLayout:YES];
+    }
   }
   return self;
 }
@@ -294,18 +298,20 @@ static const NSTimeInterval kSlideshowInterval = 2;
 }
 
 - (void)showBarsAnimationDidStop {
-  _innerView.top = -CHROME_HEIGHT;
-  self.view.top = TOOLBAR_HEIGHT;
-  self.view.height -= TOOLBAR_HEIGHT;
-
+  if (TTOSVersion() &lt; 3.0) {
+    _innerView.top = -CHROME_HEIGHT;
+    self.view.top = TOOLBAR_HEIGHT;
+    self.view.height -= TOOLBAR_HEIGHT;
+  }
   self.navigationController.navigationBarHidden = NO;
 }
 
 - (void)hideBarsAnimationDidStop {
-  _innerView.top = -STATUS_HEIGHT;
-  self.view.top = 0;
-  self.view.height += TOOLBAR_HEIGHT;
-  
+  if (TTOSVersion() &lt; 3.0) {
+    _innerView.top = -STATUS_HEIGHT;
+    self.view.top = 0;
+    self.view.height += TOOLBAR_HEIGHT;
+  }
   self.navigationController.navigationBarHidden = YES;
 }
 
@@ -316,7 +322,8 @@ static const NSTimeInterval kSlideshowInterval = 2;
   CGRect screenFrame = [UIScreen mainScreen].bounds;
   self.view = [[[TTUnclippedView alloc] initWithFrame:screenFrame] autorelease];
     
-  CGRect innerFrame = CGRectMake(0, -CHROME_HEIGHT,
+  CGFloat y = TTOSVersion() &lt; 3.0 ? -CHROME_HEIGHT : 0;
+  CGRect innerFrame = CGRectMake(0, y,
                                  screenFrame.size.width, screenFrame.size.height + CHROME_HEIGHT);
   _innerView = [[UIView alloc] initWithFrame:innerFrame];
   [self.view addSubview:_innerView];
@@ -352,14 +359,16 @@ static const NSTimeInterval kSlideshowInterval = 2;
 - (void)viewDidAppear:(BOOL)animated {
   [super viewDidAppear:animated];
 
-  if (!self.nextViewController) {
-    self.view.superview.frame = CGRectOffset(self.view.superview.frame, 0, TOOLBAR_HEIGHT);
-  }
-
-  [self hideBarsAnimationDidStop];
-  [self showBarsAnimationDidStop];
-  if (!_toolbar.alpha) {
+  if (TTOSVersion() &lt; 3.0) {
+    if (!self.nextViewController) {
+      self.view.superview.frame = CGRectOffset(self.view.superview.frame, 0, TOOLBAR_HEIGHT);
+    }
+  
     [self hideBarsAnimationDidStop];
+    [self showBarsAnimationDidStop];
+    if (!_toolbar.alpha) {
+      [self hideBarsAnimationDidStop];
+    }
   }
 }
 
@@ -368,9 +377,10 @@ static const NSTimeInterval kSlideshowInterval = 2;
 
   [self pauseAction];
 
-  self.view.superview.frame = CGRectOffset(self.view.superview.frame, 0, TOOLBAR_HEIGHT);
-  self.view.frame = CGRectOffset(self.view.frame, 0, -TOOLBAR_HEIGHT);
-  
+  if (TTOSVersion() &lt; 3.0) {
+    self.view.superview.frame = CGRectOffset(self.view.superview.frame, 0, TOOLBAR_HEIGHT);
+    self.view.frame = CGRectOffset(self.view.frame, 0, -TOOLBAR_HEIGHT);
+  }
   if (self.nextViewController) {
     [self showBars:YES animated:NO];
   }</diff>
      <filename>src/TTPhotoViewController.m</filename>
    </modified>
    <modified>
      <diff>@@ -163,7 +163,8 @@ static const CGFloat kCancelHighlightThreshold = 4;
       [_highlightedNode performDefaultAction];    
       [self setHighlightedFrame:nil];
     }
-    
+  }
+  if (!tableView || TTOSVersion() &gt;= 3.0) {
     // We definitely don't want to call this if the label is inside a TTTableView, because
     // it winds up calling touchesEnded on the table twice, triggering the link twice
     [super touchesEnded:touches withEvent:event];</diff>
      <filename>src/TTStyledTextLabel.m</filename>
    </modified>
    <modified>
      <diff>@@ -194,6 +194,10 @@ static CGFloat kThumbnailRowHeight = 79;
     self.navigationBarStyle = UIBarStyleBlackTranslucent;
     self.navigationBarTintColor = nil;
     self.statusBarStyle = UIStatusBarStyleBlackTranslucent;
+
+    if (TTOSVersion() &gt;= 3.0) {
+      [self setWantsFullScreenLayout:YES];
+    }
   }
   
   return self;
@@ -214,7 +218,8 @@ static CGFloat kThumbnailRowHeight = 79;
   self.view.autoresizesSubviews = YES;
 	self.view.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;
 
-  CGRect innerFrame = CGRectMake(0, -CHROME_HEIGHT,
+  CGFloat y = TTOSVersion() &lt; 3.0 ? -CHROME_HEIGHT : 0;
+  CGRect innerFrame = CGRectMake(0, y,
                                  screenFrame.size.width, screenFrame.size.height + CHROME_HEIGHT);
   UIView* innerView = [[UIView alloc] initWithFrame:innerFrame];
   innerView.backgroundColor = TTSTYLEVAR(backgroundColor);
@@ -238,15 +243,19 @@ static CGFloat kThumbnailRowHeight = 79;
   [super viewDidAppear:animated];
   [self suspendLoadingThumbnails:NO];
 
-  if (!self.nextViewController) {
-    self.view.superview.frame = CGRectOffset(self.view.superview.frame, 0, TOOLBAR_HEIGHT);
+  if (TTOSVersion() &lt; 3.0) {
+    if (!self.nextViewController) {
+      self.view.superview.frame = CGRectOffset(self.view.superview.frame, 0, TOOLBAR_HEIGHT);
+    }
   }
 }
 
 - (void)viewWillDisappear:(BOOL)animated {
   [super viewWillDisappear:animated];
 
-  self.view.superview.frame = CGRectOffset(self.view.superview.frame, 0, TOOLBAR_HEIGHT);
+  if (TTOSVersion() &lt; 3.0) {
+    self.view.superview.frame = CGRectOffset(self.view.superview.frame, 0, TOOLBAR_HEIGHT);
+  }
 }  
 
 - (void)viewDidDisappear:(BOOL)animated {</diff>
      <filename>src/TTThumbsViewController.m</filename>
    </modified>
    <modified>
      <diff>@@ -187,6 +187,11 @@ void TTNetworkRequestStarted();
 void TTNetworkRequestStopped();
 
 /**
+ * Gets the current version of iPhone OS.
+ */
+float TTOSVersion();
+
+/**
  * Gets the current system locale chosen by the user.
  *
  * This is necessary because [NSLocale currentLocale] always returns en_US.</diff>
      <filename>src/Three20/TTGlobal.h</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>57bd9048f42168647a66b85ebedd05db85d8d645</id>
    </parent>
  </parents>
  <author>
    <name>Joe Hewitt</name>
    <email>joe@joehewitt.com</email>
  </author>
  <url>http://github.com/facebook/three20/commit/d77ad02d462e0035e039827c7b035e6688d57c8e</url>
  <id>d77ad02d462e0035e039827c7b035e6688d57c8e</id>
  <committed-date>2009-05-28T17:11:33-07:00</committed-date>
  <authored-date>2009-05-28T17:11:33-07:00</authored-date>
  <message>* Fix the photo viewer and message composer is iPhone OS 3.0</message>
  <tree>88260d8cad63d1b57cfe3152419a24993cd21cc7</tree>
  <committer>
    <name>Joe Hewitt</name>
    <email>joe@joehewitt.com</email>
  </committer>
</commit>
