- 浏览: 769734 次
- 性别:
- 来自: 大连
文章分类
- 全部博客 (417)
- ASP.NET MVC (18)
- WEB基础 (24)
- 数据库 (69)
- iPhone (20)
- JQuery (3)
- Android (21)
- UML (8)
- C# (32)
- 移动技术 (19)
- 条码/RFID (6)
- MAC (8)
- VSS/SVN (6)
- 开卷有益 (4)
- 应用软件 (1)
- 软件工程 (1)
- java/Eclipse/tomcat (61)
- 英语学习 (2)
- 综合 (16)
- SharePoint (7)
- linux (42)
- Solaris/Unix (38)
- weblogic (12)
- c/c++ (42)
- 云 (1)
- sqlite (1)
- FTp (2)
- 项目管理 (2)
- webservice (1)
- apache (4)
- javascript (3)
- Spring/Struts/Mybatis/Hibernate (4)
- 航空业务 (1)
- 测试 (6)
- BPM (1)
最新评论
-
dashengkeji:
1a64f39292ebf4b4bed41d9d6b21ee7 ...
使用POI生成Excel文件,可以自动调整excel列宽等(转) -
zi_wu_xian:
PageOffice操作excel也可以设置表格的行高列宽,并 ...
使用POI生成Excel文件,可以自动调整excel列宽等(转) -
wanggang0321:
亲,我在pptx(office2007以上版本)转pdf的时候 ...
JODConverter]word转pdf心得分享(转) -
xiejanee:
楼主:你好!我想请问下 你在代码中用DOMDocument* ...
Xerces-C++学习之——查询修改XML文档 (转)
iPhone开发中动画效果实现分类代码是本文要介绍的内容,但是内容不是很多,主要是以代码的形式来实现动画的分类,来看详细代码,希望对你帮助!
{
[UIView beginAnimations:nil context:nil];
[UIView setAnimationRepeatCount:1];
[UIView setAnimationDuration:1];
[UIView setAnimationCurve:UIViewAnimationCurveEaseIn];
[UIView setAnimationDelegate:self];
[UIView setAnimationDidStopSelector:@selector(resetView)];
CGAffineTransform oneTransform = CGAffineTransformRotate(self.animatView.transform, degreesToRadian(180));
CGAffineTransform twoTransform = CGAffineTransformTranslate(self.animatView.transform,0,-100);
CGAffineTransform newTransform = CGAffineTransformConcat(oneTransform, twoTransform);
[self.animatView setTransform:newTransform];
[UIView commitAnimations];
}
- (void) second_animations
{
CABasicAnimation *animation = [CABasicAnimation animationWithKeyPath:@"opacity"];
[animation setDuration:1];
[animation setRepeatCount:0];
[animation setAutoreverses:YES];//自动反向动画
[animation setFromValue:[NSNumber numberWithFloat:1.0]];
[animation setToValue:[NSNumber numberWithFloat:0]];
[animation setDelegate:self];
[self.animatView.layer addAnimation:animation forKey:@"firstView-Opacity"];
}
- (void) third_animations
{
[UIView beginAnimations:nil context:nil];
[UIView setAnimationRepeatCount:1];
[UIView setAnimationDuration:1];
[UIView setAnimationCurve:UIViewAnimationCurveEaseIn];
[UIView setAnimationTransition:UIViewAnimationTransitionFlipFromRight forView:self.containView cache:YES];
[UIView setAnimationDidStopSelector:@selector(animationDidStop:finished:)];
[UIView commitAnimations];
}
- (void) fourth_animations
{
CATransition *transition = [CATransition animation];
transition.duration = 1.0f;
transition.timingFunction = [CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseInEaseOut];
transition.type = @"pageCurl"; //@"cube" @"moveIn" @"reveal" @"fade"(default) @"pageCurl"
@"pageUnCurl" @"suckEffect" @"rippleEffect" @"oglFlip"
transition.subtype = kCATransitionFromRight;
transition.removedOnCompletion = YES;
transition.fillMode = kCAFillModeBackwards;
transition.delegate = self;
[self.animatView.layer addAnimation:transition forKey:nil];
}
-(void) resetView
{
[self.animatView setTransform:CGAffineTransformRotate(self.animatView.transform, degreesToRadian(180))];
self.animatView.frame = CGRectMake(0, 0, 280, 200);
}
#pragma mark Delegate Methods
- (void)animationDidStop:(CAAnimation *) theAnimation finished:(BOOL) flag {
self.animatView.frame = CGRectMake(0, 0, 280, 200);
}
#define degreesToRadian(x) (M_PI * (x) / 180.0)
{
[UIView beginAnimations:nil context:nil];
[UIView setAnimationRepeatCount:1];
[UIView setAnimationDuration:1];
[UIView setAnimationCurve:UIViewAnimationCurveEaseIn];
[UIView setAnimationDelegate:self];
[UIView setAnimationDidStopSelector:@selector(resetView)];
CGAffineTransform oneTransform = CGAffineTransformRotate(self.animatView.transform, degreesToRadian(180));
CGAffineTransform twoTransform = CGAffineTransformTranslate(self.animatView.transform,0,-100);
CGAffineTransform newTransform = CGAffineTransformConcat(oneTransform, twoTransform);
[self.animatView setTransform:newTransform];
[UIView commitAnimations];
}
- (void) second_animations
{
CABasicAnimation *animation = [CABasicAnimation animationWithKeyPath:@"opacity"];
[animation setDuration:1];
[animation setRepeatCount:0];
[animation setAutoreverses:YES];//自动反向动画
[animation setFromValue:[NSNumber numberWithFloat:1.0]];
[animation setToValue:[NSNumber numberWithFloat:0]];
[animation setDelegate:self];
[self.animatView.layer addAnimation:animation forKey:@"firstView-Opacity"];
}
- (void) third_animations
{
[UIView beginAnimations:nil context:nil];
[UIView setAnimationRepeatCount:1];
[UIView setAnimationDuration:1];
[UIView setAnimationCurve:UIViewAnimationCurveEaseIn];
[UIView setAnimationTransition:UIViewAnimationTransitionFlipFromRight forView:self.containView cache:YES];
[UIView setAnimationDidStopSelector:@selector(animationDidStop:finished:)];
[UIView commitAnimations];
}
- (void) fourth_animations
{
CATransition *transition = [CATransition animation];
transition.duration = 1.0f;
transition.timingFunction = [CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseInEaseOut];
transition.type = @"pageCurl"; //@"cube" @"moveIn" @"reveal" @"fade"(default) @"pageCurl"
@"pageUnCurl" @"suckEffect" @"rippleEffect" @"oglFlip"
transition.subtype = kCATransitionFromRight;
transition.removedOnCompletion = YES;
transition.fillMode = kCAFillModeBackwards;
transition.delegate = self;
[self.animatView.layer addAnimation:transition forKey:nil];
}
-(void) resetView
{
[self.animatView setTransform:CGAffineTransformRotate(self.animatView.transform, degreesToRadian(180))];
self.animatView.frame = CGRectMake(0, 0, 280, 200);
}
#pragma mark Delegate Methods
- (void)animationDidStop:(CAAnimation *) theAnimation finished:(BOOL) flag {
self.animatView.frame = CGRectMake(0, 0, 280, 200);
}
#define degreesToRadian(x) (M_PI * (x) / 180.0)
发表评论
-
ios随笔4
2012-06-13 09:44 0<!-- [if gte mso 9]><x ... -
UIView
2012-02-22 11:54 875iPhone开发应用之UIView开 ... -
iso随笔3
2012-02-13 15:11 087修改UIAlertView背景 UIAlertVie ... -
ios随笔2
2011-12-31 15:35 045 判断是否是 26 个英文 zimu ... -
Lvalue required as left operand of assignment error
2011-12-31 09:25 3376Hello I get the "Lvalue re ... -
NSString常用方法(转)
2011-12-28 09:16 887http://www.cnblogs.com/phonlin/ ... -
ios随笔2
2011-12-27 14:21 045判断是否是26个英文zimu NSString* ... -
ios随笔2
2011-12-27 14:21 045判断是否是26个英文zimu NSString* ... -
tmp
2011-12-16 10:06 1279http://cache.baidu.com/c?m=9d78 ... -
todo
2011-12-12 13:30 0http://bbs.51cto.com/thread-845 ... -
iphone客户端解压gzip
2011-12-11 09:04 1663-(NSData *)uncompressZippedD ... -
HLS
2011-12-11 09:04 4386OS设备上要用原生的浏览器或者播放器来跑直播流媒体,确实是有点 ... -
Flash Media Server 4.5带来Flash末日?
2011-11-01 15:09 1443原文链接:Flash Media Se ... -
IOS开发之──应用之间调用(转)
2011-10-31 14:41 1800转自:http://blog.csdn.net/pjk1129 ... -
iPhone实战:操作SQLite(转)
2011-12-11 09:05 1897SQLite是一款轻量级的数据库,是遵守ACID的关联式数据库 ... -
内存管理
2011-12-11 09:05 853内存管理可以说是 iPhone 开发中最重要也最令人头疼的关键 ... -
连接 iPhone 的sqlite数据库的一段代码例子(转)
2011-10-26 10:39 1259原帖地址 http://www.cocoachina.com/ ... -
site
2011-10-21 17:52 960常用开发代码:http://www.cnblogs.com/K ... -
ios与android解析(转)
2011-10-17 10:45 920http://bbs.xiaomi.com/thread-34 ... -
电子杂志例子
2011-10-14 17:36 0----------- 程序结构说明及知识点 1。主体是n ...
相关推荐
电子-donghua.7z,单片机/嵌入式STM32-F0/F1/F2
hacker游戏 让你找到做黑客的感觉 RAR
再介绍一个怎样利用图形LCD去显示一个动画,这里是一只飞翔的鸟,很有趣,也很实用。
android下通过配置文件实现帧间动画,这是一种比较简单的动画实现方式
此程序可以在dos环境下实现一个小的动画效果。十分有趣
Delphi 生成FireMonkey扇形动画特效
使用二次差值算法进行数值计算,可以较简单的计算出数值。
vc 关于动画的 实现 ,对 用于界面编程案例 希望对大家有用
光棍节动画,制作了一个用于庆祝光棍节的动画程序
iPhone手机开机动画设计,iPhone手机软件开发的中心界面的动态设计
简单的小动画程序,可以给刚刚入门的同道给予一定帮助。
css+html实现全屏视频背景+响应式布局。简易入门,方便直接使用
Win32 C编程01 http://dx.3800hk.com/donghua/g/27241.html Win32 C编程02 http://dx.3800hk.com/donghua/g/27255.html Win32 C编程03 http://dx.3800hk.com/donghua/g/27358.html Win32 C编程04 ...
http://dx.3800hk.com/donghua/g/27288.html Vc++ 打造局域网聊天室(2)---聊天室界面的制作及初始化 http://www.3800hk.com/donghua/g/27317.html Vc++ 打造局域网聊天室(3)---动态启用 or 禁用窗口及MFC消息映射...
3DMAX场地一段自己K的场地MAX动画
利用到html+css +javascript 下拉菜单原理
H5酷炫3D开场动画(酷炫又不会占太大内存)H5酷炫3D开场动画(酷炫又不会占太大内存)H5酷炫3D开场动画(酷炫又不会占太大内存)
function donghua(){ $('.containter').animate({'top': -100*nowpage '%'}, 500); $('.page').eq(nowpage).addClass('current').siblings().removeClass('current'); $('.dian ul li').eq(nowpage).addClass...
左右滚动图片,每次点击均会向右(左)移动一个单位,效果很不错 不过推荐的理由不是这个,而是在高版本浏览器下,鼠标在图片上悬停的时候有一定的动画效果
绝品真正的震撼,优于ireader的3D翻页,赠予有缘人