From 21d3023a9b7b6aff68c1170e345951396b1c6cfd Mon Sep 17 00:00:00 2001
From: 单军华
Date: Tue, 31 Jul 2018 13:35:21 +0800
Subject: [PATCH] no message

---
 screendisplay/screendisplay/Classes/检测/Controller/MyAnimatedAnnotationView.m |   47 +++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 47 insertions(+), 0 deletions(-)

diff --git "a/screendisplay/screendisplay/Classes/\346\243\200\346\265\213/Controller/MyAnimatedAnnotationView.m" "b/screendisplay/screendisplay/Classes/\346\243\200\346\265\213/Controller/MyAnimatedAnnotationView.m"
new file mode 100644
index 0000000..34e8e50
--- /dev/null
+++ "b/screendisplay/screendisplay/Classes/\346\243\200\346\265\213/Controller/MyAnimatedAnnotationView.m"
@@ -0,0 +1,47 @@
+//
+//  MyAnimatedAnnotationView.m
+//  IphoneMapSdkDemo
+//
+//  Created by wzy on 14-11-27.
+//  Copyright (c) 2014��� Baidu. All rights reserved.
+//
+
+#import "MyAnimatedAnnotationView.h"
+
+@implementation MyAnimatedAnnotationView
+
+@synthesize annotationImageView = _annotationImageView;
+@synthesize annotationImages = _annotationImages;
+
+- (id)initWithAnnotation:(id<BMKAnnotation>)annotation reuseIdentifier:(NSString *)reuseIdentifier {
+    self = [super initWithAnnotation:annotation reuseIdentifier:reuseIdentifier];
+    if (self) {
+//        [self setBounds:CGRectMake(0.f, 0.f, 30.f, 30.f)];
+        [self setBounds:CGRectMake(0.f, 0.f, 32.f, 32.f)];
+
+        [self setBackgroundColor:[UIColor clearColor]];
+        
+        _annotationImageView = [[UIImageView alloc] initWithFrame:self.bounds];
+        _annotationImageView.contentMode = UIViewContentModeCenter;
+        [self addSubview:_annotationImageView];
+    }
+    return self;
+}
+
+- (void)setAnnotationImages:(NSMutableArray *)images {
+    _annotationImages = images;
+    [self updateImageView];
+}
+
+- (void)updateImageView {
+    if ([_annotationImageView isAnimating]) {
+        [_annotationImageView stopAnimating];
+    }
+    
+    _annotationImageView.animationImages = _annotationImages;
+    _annotationImageView.animationDuration = 0.5 * [_annotationImages count];
+    _annotationImageView.animationRepeatCount = 0;
+    [_annotationImageView startAnimating];
+}
+
+@end

--
Gitblit v1.8.0