1、声明NSTimer *timer;2、定义timer= [NSTimerscheduledTimerWithTimeInterval:1.0ftarget:selfselector:@selector(updateValue)userInfo:nilrepeats:YES];以下是调用函数...
分类:
移动开发 时间:
2014-10-25 17:19:32
阅读次数:
187
第一种:用CADisplayLink可以实现不停重绘。例子:CADisplayLink* gameTimer;gameTimer= [CADisplayLink displayLinkWithTarget:selfselector:@selector(updateDisplay:)];[gameTi...
分类:
其他好文 时间:
2014-10-25 17:18:09
阅读次数:
214
调用一次计时器方法:[cpp]view plaincopymyTimer=[NSTimerscheduledTimerWithTimeInterval:1.5target:selfselector:@selector(scrollTimer)userInfo:nilrepeats:NO];//不重复...
分类:
移动开发 时间:
2014-10-25 17:16:51
阅读次数:
171
1、初始化+ (NSTimer *)timerWithTimeInterval:(NSTimeInterval)ti target:(id)aTarget selector:(SEL)aSelector userInfo:(id)userInfo repeats:(BOOL)yesOrNo;+ (N...
分类:
移动开发 时间:
2014-10-25 17:12:08
阅读次数:
245
就爬取和解析内容而言,我们有太多选择。比如,很多人都觉得Jsoup就可以解决所有问题。无论是Http请求、DOM操作、CSS query selector筛选都非常方便。 关键是这个selector,仅通过一个表达式筛选出的只能是一个node。如过我想获得一个text或者一个node的属性值,我需要...
分类:
编程语言 时间:
2014-10-24 21:59:32
阅读次数:
241
用两张图片做了个selector,使用ImageView的src或background使用selector点击时,总没出现点击效果,这是为什么呢?经常一番折腾后来才发现一个“秘密”。先不公开,大家
来看一看:
上面的例子,你们试试,使用时不会出现点击效果。
这个例子,会出现点击效果。
总结经验:de...
分类:
其他好文 时间:
2014-10-24 16:41:04
阅读次数:
353
一、基本语法
1、fadeIn淡入、fadeOut淡出、fadeToggle淡入淡出切换(已经淡出点击淡入,或者相反):
$(selector).fadeIn(duration,complete);$(selector).fadeOut(duration,complete);$(selector).fadeToggle(duration,complete);
可选的 speed 参数规定...
分类:
Web程序 时间:
2014-10-24 16:28:47
阅读次数:
274
1.Reachability// 监听网络状态改变的通知[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(networkStateChange) name:kReachabilityChangedNot...
分类:
移动开发 时间:
2014-10-24 16:22:23
阅读次数:
343
[_yourTextField addTarget:self action:@selector(eventEditingChange:) forControlEvents:UIControlEventEditingChanged];-(void)eventEditingChange:(UITextF...
分类:
其他好文 时间:
2014-10-24 14:16:58
阅读次数:
203
最近在做一个项目,里边的设置页面要求圆角选项,类似QQ浏览器中的设置页面。...
分类:
其他好文 时间:
2014-10-24 10:57:50
阅读次数:
202