|
@@ -448,25 +448,25 @@
|
|
|
|
|
|
- (void)highlightWhenMatchKeyword:(NSString *)keyword {
|
|
|
static NSString *const key = @"highlightAnimation";
|
|
|
- if (keyword && keyword.length) {
|
|
|
- if (self.highlightAnimating) {
|
|
|
- return;
|
|
|
- }
|
|
|
- self.highlightAnimating = YES;
|
|
|
- CAKeyframeAnimation *animation = [CAKeyframeAnimation animationWithKeyPath:@"backgroundColor"];
|
|
|
- animation.repeatCount = 3;
|
|
|
- animation.values = @[
|
|
|
- (id)[[UIColor orangeColor] colorWithAlphaComponent:0.2].CGColor,
|
|
|
- (id)[[UIColor orangeColor] colorWithAlphaComponent:0.5].CGColor,
|
|
|
- (id)[[UIColor orangeColor] colorWithAlphaComponent:0.2].CGColor,
|
|
|
- ];
|
|
|
- animation.duration = 0.5;
|
|
|
- animation.removedOnCompletion = YES;
|
|
|
- animation.delegate = self;
|
|
|
- [self.highlightAnimateView.layer addAnimation:animation forKey:key];
|
|
|
- } else {
|
|
|
- [self.highlightAnimateView.layer removeAnimationForKey:key];
|
|
|
- }
|
|
|
+// if (keyword && keyword.length) {
|
|
|
+// if (self.highlightAnimating) {
|
|
|
+// return;
|
|
|
+// }
|
|
|
+// self.highlightAnimating = YES;
|
|
|
+// CAKeyframeAnimation *animation = [CAKeyframeAnimation animationWithKeyPath:@"backgroundColor"];
|
|
|
+// animation.repeatCount = 3;
|
|
|
+// animation.values = @[
|
|
|
+// (id)[[UIColor orangeColor] colorWithAlphaComponent:0.2].CGColor,
|
|
|
+// (id)[[UIColor orangeColor] colorWithAlphaComponent:0.5].CGColor,
|
|
|
+// (id)[[UIColor orangeColor] colorWithAlphaComponent:0.2].CGColor,
|
|
|
+// ];
|
|
|
+// animation.duration = 0.5;
|
|
|
+// animation.removedOnCompletion = YES;
|
|
|
+// animation.delegate = self;
|
|
|
+// [self.highlightAnimateView.layer addAnimation:animation forKey:key];
|
|
|
+// } else {
|
|
|
+// [self.highlightAnimateView.layer removeAnimationForKey:key];
|
|
|
+// }
|
|
|
}
|
|
|
|
|
|
- (void)updateReadLabelText {
|