Changed upper map in 2-map sample to MS Virtual Earth. Neither map shows correct…
… map initially. Manually pan/zoom updates it. Can you solve it?
Showing
1 changed file
with
6 additions
and
2 deletions
@@ -6,6 +6,7 @@ | @@ -6,6 +6,7 @@ | ||
6 | #import "MainViewController.h" | 6 | #import "MainViewController.h" |
7 | #import "MapTestbedTwoMapsAppDelegate.h" | 7 | #import "MapTestbedTwoMapsAppDelegate.h" |
8 | #import "RMCloudMadeMapSource.h" | 8 | #import "RMCloudMadeMapSource.h" |
9 | +#import "RMVirtualEarthSource.h" | ||
9 | 10 | ||
10 | #import "MainView.h" | 11 | #import "MainView.h" |
11 | 12 | ||
@@ -27,13 +28,16 @@ | @@ -27,13 +28,16 @@ | ||
27 | [super viewDidLoad]; | 28 | [super viewDidLoad]; |
28 | 29 | ||
29 | [upperMapView setDelegate:self]; | 30 | [upperMapView setDelegate:self]; |
30 | - [(MapTestbedTwoMapsAppDelegate *)[[UIApplication sharedApplication] delegate] setUpperMapContents:[upperMapView contents]]; | ||
31 | upperMapContents = [upperMapView contents]; | 31 | upperMapContents = [upperMapView contents]; |
32 | + [upperMapContents setTileSource:[[[RMVirtualEarthSource alloc] init] autorelease]]; | ||
33 | + [(MapTestbedTwoMapsAppDelegate *)[[UIApplication sharedApplication] delegate] setUpperMapContents:[upperMapView contents]]; | ||
34 | + [upperMapView setNeedsLayout]; | ||
35 | + [upperMapView setNeedsDisplay]; | ||
32 | 36 | ||
33 | [lowerMapView setDelegate:self]; | 37 | [lowerMapView setDelegate:self]; |
34 | - [(MapTestbedTwoMapsAppDelegate *)[[UIApplication sharedApplication] delegate] setLowerMapContents:[lowerMapView contents]]; | ||
35 | lowerMapContents = [lowerMapView contents]; | 38 | lowerMapContents = [lowerMapView contents]; |
36 | [lowerMapContents setTileSource:[[[RMCloudMadeMapSource alloc] init] autorelease]]; | 39 | [lowerMapContents setTileSource:[[[RMCloudMadeMapSource alloc] init] autorelease]]; |
40 | + [(MapTestbedTwoMapsAppDelegate *)[[UIApplication sharedApplication] delegate] setLowerMapContents:[lowerMapView contents]]; | ||
37 | [lowerMapView setNeedsDisplay]; | 41 | [lowerMapView setNeedsDisplay]; |
38 | } | 42 | } |
39 | 43 |
-
Please register or login to post a comment