1. 新建两个视图控制器类(继承自UIViewController), 在AppDelegate.m中指定根视图控制器#import "AppDelegate.h"#import "RootViewController.h"#import "LeadViewController.h"@interfa...
分类:
移动开发 时间:
2015-12-08 22:12:36
阅读次数:
248
1.状态栏高亮颜色在info.plist中添加View controller-based status bar appearance设置为 "NO"在AppDelegate.m中添加代码[[UIApplication sharedApplication] setStatusBarStyle:UISt...
分类:
移动开发 时间:
2015-12-08 20:14:58
阅读次数:
135
#import "AppDelegate.h"#import "MyTableViewController.h"@interfaceAppDelegate ()@end@implementation AppDelegate- (BOOL)application:(UIApplication *)ap...
分类:
其他好文 时间:
2015-12-08 00:24:27
阅读次数:
263
错误原因在于 AppDelegate 中 didFinishLaunchingWithOptions 结束前 未定义 rootViewController,Xcode7规定必须要有rootViewController。定义一个空UIViewController即可,添加如下代码解决:UIViewCo...
分类:
移动开发 时间:
2015-12-07 14:01:42
阅读次数:
208
统一设置导航栏与状态栏代码:#import "AppDelegate.h"#import "SZMMainTabBarController.h"@interface AppDelegate ()@end@implementation AppDelegate- (BOOL)application:(U...
分类:
其他好文 时间:
2015-12-06 11:16:11
阅读次数:
146
一.简介 很多iOS应用都支持偏好设置,主要用于存储个人保密信息。比如保存用户名,密码,是否自动登录等设置,iOS提供了一套标准的解决方案来为应用加入偏好设置功能。每个应用都有个NSUserDefaults实例,通过它来存取偏好设置. 二.代码实现AppDelegate.m//NSU...
分类:
移动开发 时间:
2015-12-06 01:47:39
阅读次数:
222
//// AppDelegate.m// NiHongPractice//#import "AppDelegate.h"#define kColorValue arc4random_uniform(256) / 255.0#define kScreenWidth [UIScreen mainSc.....
分类:
其他好文 时间:
2015-12-06 00:02:18
阅读次数:
167
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions{ self.window = [[UIWindow alloc] init...
分类:
移动开发 时间:
2015-12-01 14:49:47
阅读次数:
204
#import "AppDelegate.h"#import "ViewController.h"#import "stdlib.h"@interface AppDelegate (){ UIView *view1; }@end@implementation AppDelegate- (BOOL)....
分类:
其他好文 时间:
2015-11-30 22:17:51
阅读次数:
236
1,首先创建一个实体类(student)2,进入程序在viewcontroller.m中#import "ViewController.h"#import "AppDelegate.h"#import "Student.h"@interface ViewController ()@end@imple...
分类:
其他好文 时间:
2015-11-30 20:28:54
阅读次数:
110