小编Rag*_*jji的帖子

闪烁自定义标记在Google地图iOS中

我在谷歌地图iOS SDK中放置了6个具有相同坐标的自定义标记.这些标记持续闪烁/切换.我根本不想要动画闪烁.请帮我.

这是我的源代码.

-(void)loadPlacesInMapWithIndex:(int)index{

    for (int i = 0; i < [[[SearchManager sharedInstance]searchedStallArray] count]; i++) {
        Stall *stall = [[[SearchManager sharedInstance]searchedStallArray] objectAtIndex:i];

        // Creates a marker in the center of the map.
        GMSMarker *marker = [[GMSMarker alloc] init];
        marker.position = CLLocationCoordinate2DMake([stall.stallLatitude doubleValue],[stall.stallLongitude doubleValue]);
        marker.infoWindowAnchor = CGPointMake(0.44f, -0.07f);
        marker.userData = stall;
        marker.tappable = YES;
        self.infoView = [[[NSBundle mainBundle]loadNibNamed:@"StallInfoWindow" owner:self options:nil] objectAtIndex:0];

        marker.iconView = self.infoView;
        if (index == i) {
            [self.infoView.stallPinImageView setImage:[UIImage imageNamed:@"RateLabel.png"]];
            [self.infoView.stallPriceLabel setTextColor:[UIColor whiteColor]];

            CGFloat currentZoom = self.stallsMapView.camera.zoom;
            [CATransaction begin]; …
Run Code Online (Sandbox Code Playgroud)

objective-c google-maps-markers ios google-maps-sdk-ios

6
推荐指数
2
解决办法
2136
查看次数