运行以下动画。请[upwardView.layer removeAllAnimations];
IBAction
发送button
。如果有人能为另一个菜鸟做点什么。
UIView* upwardView=[[UIView alloc]init];
[upwardView setFrame:CGRectMake(10, 175, 86, 140)];
[self.view addSubview:upwardView];
[self.stageView addSubview:upwardView];
NSArray *animationImages=[NSArray arrayWithObjects:
[UIImage imageNamed:@"win_1.png"],
[UIImage imageNamed:@"win_2.png"],
[UIImage imageNamed:@"win_3.png"],
[UIImage imageNamed:@"win_4.png"],
[UIImage imageNamed:@"win_5.png"],
[UIImage imageNamed:@"win_6.png"],
[UIImage imageNamed:@"win_7.png"],
[UIImage imageNamed:@"win_8.png"],
[UIImage imageNamed:@"win_9.png"],
[UIImage imageNamed:@"win_10.png"],
[UIImage imageNamed:@"win_11.png"],
[UIImage imageNamed:@"win_12.png"],
[UIImage imageNamed:@"win_13.png"],
[UIImage imageNamed:@"win_14.png"],
[UIImage imageNamed:@"win_15.png"],nil];
CAKeyframeAnimation *animationSequence = [CAKeyframeAnimation animationWithKeyPath: @"contents"];
animationSequence.calculationMode = kCAAnimationLinear;
animationSequence.autoreverses = NO;
animationSequence.duration = 0.90;
animationSequence.repeatCount = HUGE_VALF;
animationSequence.beginTime = 0;
NSMutableArray *animationSequenceArray = [[NSMutableArray alloc] init];
for (UIImage *image in animationImages)
{
[animationSequenceArray addObject:(id)image.CGImage];
}
CALayer *layer = [upwardView layer];
animationSequence.values = animationSequenceArray;
[layer addAnimation:animationSequence forKey:@"contents"];
答案 0 :(得分:1)
为什么要将upgradeView添加到self.view和self.stageView?删除此
ALTER TABLE [tblename] ALTER COLUMN [columnname] SET DEFAULT <defaultvalue>
线。它应该完美无缺。