Permalink
Browse files

Cleaned up a bit. Also updated deployment target to iOS 4.0

  • Loading branch information...
1 parent 42bd1af commit 15bc6f72e140fb89918d5dfc942815853a395ae2 @dyang committed May 22, 2012
@@ -14,7 +14,7 @@
411D3B507540A47B8DB88804 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 411D3B507540A47B8DB88803 /* main.m */; };
411D3B507540A47B8DB88808 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 411D3B507540A47B8DB88807 /* AppDelegate.m */; };
411D3B507540A47B8DB8880B /* RootViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 411D3B507540A47B8DB8880A /* RootViewController.m */; };
- 411D3B507540A47B8DB8880E /* DYViewController.xib in Resources */ = {isa = PBXBuildFile; };
+ 411D3B507540A47B8DB8880E /* (null) in Resources */ = {isa = PBXBuildFile; };
411D3B507540A47B8DB88813 /* DYNavigationController.m in Sources */ = {isa = PBXBuildFile; fileRef = 411D3B507540A47B8DB88812 /* DYNavigationController.m */; };
411D3B507540A47B8DB88816 /* DetailViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 411D3B507540A47B8DB88815 /* DetailViewController.m */; };
/* End PBXBuildFile section */
@@ -170,7 +170,7 @@
buildActionMask = 2147483647;
files = (
411D3B507540A47B8DB88802 /* InfoPlist.strings in Resources */,
- 411D3B507540A47B8DB8880E /* DYViewController.xib in Resources */,
+ 411D3B507540A47B8DB8880E /* (null) in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -252,6 +252,7 @@
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "DYNavigationController/DYNavigationController-Prefix.pch";
INFOPLIST_FILE = "DYNavigationController/DYNavigationController-Info.plist";
+ IPHONEOS_DEPLOYMENT_TARGET = 4.0;
PRODUCT_NAME = "$(TARGET_NAME)";
WRAPPER_EXTENSION = app;
};
@@ -263,6 +264,7 @@
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "DYNavigationController/DYNavigationController-Prefix.pch";
INFOPLIST_FILE = "DYNavigationController/DYNavigationController-Info.plist";
+ IPHONEOS_DEPLOYMENT_TARGET = 4.0;
PRODUCT_NAME = "$(TARGET_NAME)";
WRAPPER_EXTENSION = app;
};
@@ -287,6 +289,7 @@
411D3B507540A47B8DB887F2 /* Debug */,
);
defaultConfigurationIsVisible = 0;
+ defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
@@ -2,40 +2,39 @@
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
-
- <key>CFBundleIdentifier</key>
- <string>com.iappexperience.${PRODUCT_NAME:rfc1034identifier}</string>
-
- <key>CFBundleDevelopmentRegion</key>
- <string>en</string>
- <key>CFBundleExecutable</key>
- <string>${EXECUTABLE_NAME}</string>
- <key>CFBundleInfoDictionaryVersion</key>
- <string>6.0</string>
- <key>CFBundleName</key>
- <string>${PRODUCT_NAME}</string>
- <key>CFBundlePackageType</key>
- <string>APPL</string>
- <key>CFBundleSignature</key>
- <string>????</string>
-
- <key>CFBundleDisplayName</key>
- <string>${PRODUCT_NAME}</string>
- <key>CFBundleVersion</key>
- <string>1.0</string>
- <key>CFBundleShortVersionString</key>
- <string>1.0</string>
- <key>LSRequiresIPhoneOS</key>
- <true/>
- <key>UIRequiredDeviceCapabilities</key>
- <array>
- <string>armv7</string>
- </array>
- <key>UISupportedInterfaceOrientations</key>
- <array>
- <string>UIInterfaceOrientationPortrait</string>
- <string>UIInterfaceOrientationLandscapeLeft</string>
- <string>UIInterfaceOrientationLandscapeRight</string>
- </array>
+ <key>CFBundleIdentifier</key>
+ <string>com.iappexperience.${PRODUCT_NAME:rfc1034identifier}</string>
+ <key>CFBundleDevelopmentRegion</key>
+ <string>en</string>
+ <key>CFBundleExecutable</key>
+ <string>${EXECUTABLE_NAME}</string>
+ <key>CFBundleInfoDictionaryVersion</key>
+ <string>6.0</string>
+ <key>CFBundleName</key>
+ <string>${PRODUCT_NAME}</string>
+ <key>CFBundlePackageType</key>
+ <string>APPL</string>
+ <key>CFBundleSignature</key>
+ <string>????</string>
+ <key>CFBundleDisplayName</key>
+ <string>${PRODUCT_NAME}</string>
+ <key>CFBundleVersion</key>
+ <string>1.0</string>
+ <key>CFBundleShortVersionString</key>
+ <string>1.0</string>
+ <key>LSRequiresIPhoneOS</key>
+ <true/>
+ <key>UIRequiredDeviceCapabilities</key>
+ <array>
+ <string>armv7</string>
+ </array>
+ <key>UISupportedInterfaceOrientations</key>
+ <array>
+ <string>UIInterfaceOrientationPortrait</string>
+ <string>UIInterfaceOrientationLandscapeLeft</string>
+ <string>UIInterfaceOrientationLandscapeRight</string>
+ </array>
+ <key>UIStatusBarHidden</key>
+ <true/>
</dict>
-</plist>
+</plist>
@@ -97,11 +97,11 @@ - (void)setNavigatorIfNeeded:(UIViewController *)viewController {
}
}
-- (UIViewController<DYNavigationControllerDelegate> *)currentViewController {
+- (UIViewController *)currentViewController {
return [self.viewControllerStack lastObject];
}
-- (UIViewController<DYNavigationControllerDelegate> *)previousViewController {
+- (UIViewController *)previousViewController {
return [self.viewControllerStack objectAtIndex:self.viewControllerStack.count - 2];
}
@@ -22,28 +22,24 @@ - (void)viewDidLoad
UILabel *popInstruction = [[UILabel alloc] initWithFrame:CGRectMake(10, 100, 300, 40)];
popInstruction.backgroundColor = [UIColor clearColor];
- popInstruction.text = @"Swipe right to go back to previous view";
+ popInstruction.text = @"Swipe right to pop current view out";
+ popInstruction.textAlignment = UITextAlignmentCenter;
[self.view addSubview:popInstruction];
[popInstruction release];
UILabel *pushInstruction = [[UILabel alloc] initWithFrame:CGRectMake(10, 160, 300, 40)];
pushInstruction.backgroundColor = [UIColor clearColor];
- pushInstruction.text = @"Swipe left to reveal one more view";
+ pushInstruction.text = @"Swipe left to push a new view in";
+ pushInstruction.textAlignment = UITextAlignmentCenter;
[self.view addSubview:pushInstruction];
[pushInstruction release];
}
-- (void)viewDidUnload
-{
- [super viewDidUnload];
- // Release any retained subviews of the main view.
-}
-
#pragma mark - DYNavigationControllerDelegate
- (UIViewController *)viewControllerToPush {
UIViewController *anotherDetailViewController = [[UIViewController alloc] init];
- anotherDetailViewController.view.backgroundColor = [UIColor blueColor];
+ anotherDetailViewController.view.backgroundColor = [UIColor lightGrayColor];
return [anotherDetailViewController autorelease];
}
@@ -44,8 +44,8 @@ - (void)viewDidUnload
- (void)setUpButtons {
UIButton *right = [UIButton buttonWithType:UIButtonTypeRoundedRect];
- [right setTitle:@"Right" forState:UIControlStateNormal];
- [right setFrame:CGRectMake(100, 100, 80, 40)];
+ [right setTitle:@"Tap to push a new view in" forState:UIControlStateNormal];
+ [right setFrame:CGRectMake(50, 100, 220, 40)];
[right addTarget:self action:@selector(pushNewViewIn) forControlEvents:UIControlEventTouchUpInside];
[self.view addSubview:right];
}

0 comments on commit 15bc6f7

Please sign in to comment.