IOS技术点总结(点点点)

技术点总结:

滚动视图:(第三方)

配置第三方:pod ‘XLsn0wLoop’

并导入头文件

三步  轻松实现滚动视图

//2:更改根视图方法:

TwoViewController *theTC = [[TwoViewController alloc]init];

AppDelegate * app = (AppDelegate *)[UIApplication sharedApplication].delegate;

app.window.rootViewController = theTC;

//3:判断首次登录

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {

// Override point for customization after application launch.

//  使用NSUserDefaults来判断程序是否第一次启动

NSUserDefaults *TimeOfBootCount = [NSUserDefaults standardUserDefaults];

if (![TimeOfBootCount valueForKey:@"time"]) {

[TimeOfBootCount setValue:@"sd" forKey:@"time"];

NSLog(@"第一次启动");

ViewController *theV = [[ViewController alloc]init];

UINavigationController *theNC=  [[UINavigationController alloc]initWithRootViewController:theV];

self.window.rootViewController = theNC;

}else{

NSLog(@"不是第一次启动");

TwoViewController *theV = [[TwoViewController alloc]init];

UINavigationController *theNC=  [[UINavigationController alloc]initWithRootViewController:theV];

self.window.rootViewController = theNC;

}

NSLog(@"启动成功");

return YES;

}

创建Plist文件,并读取文件

参考:

http://blog.csdn.net/totogo2010/article/details/7634185

表格跳转与传值

-(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath

{

ThreeViewController *theTa= [[ThreeViewController alloc]init];

theTa.theA = theArr[indexPath.row];

[self.navigationController pushViewController:theTa animated:NO];

}

实现音乐播放

http://www.jb51.net/article/80550.htm

-(void)viewDidDisappear:(BOOL)animated

此文档仅供参考,

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容

  • *7月8日上午 N:Block :跟一个函数块差不多,会对里面所有的内容的引用计数+1,想要解决就用__block...
    炙冰阅读 2,547评论 1 14
  • 1.自定义控件 a.继承某个控件 b.重写initWithFrame方法可以设置一些它的属性 c.在layouts...
    圍繞的城阅读 3,475评论 2 4
  • 1、禁止手机睡眠[UIApplication sharedApplication].idleTimerDisabl...
    DingGa阅读 1,144评论 1 6
  • 感恩昨天早晨就帮花友卖了一棵花,自己也小赚了20,虽然不多,很有成就感。 感恩昨天同事中午请我吃饭!感恩他的热情大...
    愛月亮的魚兒爱阅读 178评论 0 2
  • 暑假,带了两批孩子去参加军事夏令营。这些孩子以小学生为主,也有一些初中和高中的孩子。 军事营,最大的特色就是让孩子...
    王立旗家庭教育阅读 2,112评论 0 8