MKMapView showing blank screen in iOS 8

本小妞迷上赌 提交于 2020-01-29 07:24:04

问题


I am having an issue with displaying a MKMapView in iOS 8.

It worked fine in iOS 7 and it is working fine now but only on simulator.

On device it shows only annotations but no map behind.

It looks like this: http://imgur.com/rBVWTeD

The error that I am getting:

2014-09-24 22:07:15.349 xxx[1509:265380] Stylesheet does not include style matching tree, or includes an old version.  Perhaps it was compiled by an old version of the style compiler.
2014-09-24 22:07:15.351 xxx[1509:265380] Please create a radar about this! (Check it's not a dup of rdar://16346611 first though)
2014-09-24 22:07:15.351 xxx[1509:265380] Active tile set: GEOActiveTileSet

My code:

    CLLocationCoordinate2D coord = CLLocationCoordinate2DMake(21.779998, 59.447816);

    MKCoordinateSpan span = MKCoordinateSpanMake(0.007, 0.007);
    MKCoordinateRegion region = {coord, span};

    MKPointAnnotation *annotation = [[MKPointAnnotation alloc] init];
    [annotation setCoordinate:coord];
    [annotation setTitle:@"yyy"];

    [self.cell.myMapView setRegion:region];
    [self.cell.myMapView addAnnotation:annotation];
    [self.cell.myMapView setDelegate:self];

Thanks in advance!


回答1:


Link CoreGraphics framework to your target. Should fix that.



来源:https://stackoverflow.com/questions/26037700/mkmapview-showing-blank-screen-in-ios-8

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!