splitviewController의 첫 번째 viewController에있는 표의 경우 깜박이는 애니메이션을 tableViewcell
의 contentView
에 적용했습니다. 내 문제는 내가있는 UITableViewCell 하위 클래스했다 splitViewController분할 뷰 컨트롤러의 마스터가 숨겨지면 코어 애니메이션이 중지됩니다 (세로 모드에서)?
의 presentsWithGesture
특성으로 FirstViewcontroller을 숨기고 속성과 을 설정하는 동안 나는 내가 좋아하는 cell
의 contentView
에 애니메이션을 추가 애니메이션을 추가 할 때 애니메이션이 중지입니다
-(void)setProperty:(Property *)aProperty
{
_property=aProperty;
[self.contentView addSubview:self.dateLabel];
self.dateLabel.text=[self.meeting stringforScheduleDate];
if (_property.opened) {
CABasicAnimation *theAnimation;
CALayer *layer=[self.contentView layer];
theAnimation=[CABasicAnimation animationWithKeyPath:@"opacity"];
theAnimation.duration = 0.5;
theAnimation.delegate=self;
theAnimation.fromValue = [NSNumber numberWithFloat:0.0];
theAnimation.toValue = [NSNumber numberWithFloat:1.0];
theAnimation.repeatCount=HUGE_VALF;
theAnimation.autoreverses=YES;
// [layer removeAnimationForKey:@"opacity"];
[layer addAnimation:theAnimation forKey:@"opacity"];
}
else
{
CALayer *layer=[self.contentView layer];
[layer removeAnimationForKey:@"opacity"];
}
}
아래
보이지 않을 때 뷰 계층 구조에서 핵심 애니메이션을 멈추는 ViewController의 동작인지 또는 내 코드에서 무언가를 놓쳤는지를 알지 못합니다. 그래서 동료들 도와주세요
안녕하세요 Vignesh, 솔루션을 찾고 계십니까? – doNotCheckMyBlog
@doNotCheckMyBlog 예, 일시적으로 viewDidAppear에서 tableView를 다시로드하여 애니메이션이 아직있는 것처럼 보이게합니다. –
uitableviewcell의 [CABasicAnimation] 중 가능한 중복이 작동하지 않는 것 같습니다. (http://stackoverflow.com/questions/26941027/cabasicanimation-in-uitableviewcell-doesnt-seem-to-work) – Fattie