Authored by Thomas Rasch

Merge branch 'develop' into release

1 // 1 //
2 -// RMTileStreamSource.h 2 +// RMMapBoxSource.h
3 // 3 //
4 // Created by Justin R. Miller on 5/17/11. 4 // Created by Justin R. Miller on 5/17/11.
5 -// Copyright 2011, Development Seed, Inc. 5 +// Copyright 2012 MapBox.
6 // All rights reserved. 6 // All rights reserved.
7 // 7 //
8 // Redistribution and use in source and binary forms, with or without 8 // Redistribution and use in source and binary forms, with or without
@@ -15,9 +15,9 @@ @@ -15,9 +15,9 @@
15 // notice, this list of conditions and the following disclaimer in the 15 // notice, this list of conditions and the following disclaimer in the
16 // documentation and/or other materials provided with the distribution. 16 // documentation and/or other materials provided with the distribution.
17 // 17 //
18 -// * Neither the name of Development Seed, Inc., nor the names of its  
19 -// contributors may be used to endorse or promote products derived from  
20 -// this software without specific prior written permission. 18 +// * Neither the name of MapBox, nor the names of its contributors may be
  19 +// used to endorse or promote products derived from this software
  20 +// without specific prior written permission.
21 // 21 //
22 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 22 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
23 // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 23 // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
@@ -30,50 +30,43 @@ @@ -30,50 +30,43 @@
30 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 30 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
31 // SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 31 // SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 // 32 //
33 -// http://mapbox.com/hosting/api/ 33 +// This source supports both tiles from MapBox Hosting as well as the open source,
  34 +// self-hosted TileStream software.
34 // 35 //
35 -// See samples/MBTilesDemo for example usage 36 +// When initializing an instance, pass in valid TileJSON 2.0.0[1] as returned by
  37 +// the MapBox Hosting API[2] or TileStream software[3].
36 // 38 //
37 -// This class supports both the paid, hosted version of TileStream, as well as the  
38 -// open source, self-hosted version. 39 +// Example app at https://github.com/mapbox/mapbox-ios-example
39 // 40 //
40 -// When initializing an instance, pass in an info dictionary comprised of the  
41 -// following keys. Unless otherwise specified, keys & values are exactly as  
42 -// returned by the TileStream REST API.  
43 -//  
44 -// Example: http://tiles.mapbox.com/mapbox/api/v1/Tileset/geography-class  
45 -//  
46 -// Required info dictionary keys:  
47 -//  
48 -// `name`  
49 -// `id`  
50 -// `version`  
51 -// `description`  
52 -// `attribution`  
53 -// `type`  
54 -// `minzoom`  
55 -// `maxzoom`  
56 -// `bounds`  
57 -// `tileURL` (choose a single value from `tiles` as returned by the API) 41 +// [1] https://github.com/mapbox/TileJSON/tree/master/2.0.0
  42 +// [2] http://mapbox.com/hosting/api/
  43 +// [3] https://github.com/mapbox/tilestream
58 // 44 //
  45 +// This class also supports initialization via the deprecated info dictionary
  46 +// for backwards compatibility and for iOS < 5.0 where JSON serialization isn't
  47 +// built into the SDK. Its use is discouraged.
59 48
60 #import "RMAbstractWebMapSource.h" 49 #import "RMAbstractWebMapSource.h"
61 50
62 -#define kTileStreamDefaultTileSize 256  
63 -#define kTileStreamDefaultMinTileZoom 0  
64 -#define kTileStreamDefaultMaxTileZoom 18  
65 -#define kTileStreamDefaultLatLonBoundingBox ((RMSphericalTrapezium){ .northEast = { .latitude = 90, .longitude = 180 }, \  
66 - .southWest = { .latitude = -90, .longitude = -180 } }) 51 +#define kMapBoxDefaultTileSize 256
  52 +#define kMapBoxDefaultMinTileZoom 0
  53 +#define kMapBoxDefaultMaxTileZoom 18
  54 +#define kMapBoxDefaultLatLonBoundingBox ((RMSphericalTrapezium){ .northEast = { .latitude = 90, .longitude = 180 }, \
  55 + .southWest = { .latitude = -90, .longitude = -180 } })
  56 +
  57 +@interface RMMapBoxSource : RMAbstractWebMapSource
  58 +
  59 +- (id)initWithReferenceURL:(NSURL *)referenceURL; // Designated initializer. Point to either a remote TileJSON spec or a local TileJSON or property list.
  60 +
  61 +//
  62 +// You may also use just `init` to get MapBox Streets by default.
  63 +//
67 64
68 -@interface RMTileStreamSource : RMAbstractWebMapSource  
69 -{  
70 - NSDictionary *infoDictionary;  
71 -} 65 +- (id)initWithTileJSON:(NSString *)tileJSON; // Initialize source with TileJSON.
  66 +- (id)initWithInfo:(NSDictionary *)info; // Initialize source with properly list (deprecated).
72 67
73 -- (id)initWithInfo:(NSDictionary *)info;  
74 -- (id)initWithReferenceURL:(NSURL *)referenceURL;  
75 -- (BOOL)coversFullWorld;  
76 -- (NSString *)legend; 68 +- (NSString *)legend; // HTML-formatted legend for this source, if any
  69 +- (BOOL)coversFullWorld; // Regional or global coverage?
77 70
78 @property (nonatomic, readonly, retain) NSDictionary *infoDictionary; 71 @property (nonatomic, readonly, retain) NSDictionary *infoDictionary;
79 72
1 // 1 //
2 -// RMTileStreamSource.h 2 +// RMMapBoxSource.m
3 // 3 //
4 // Created by Justin R. Miller on 5/17/11. 4 // Created by Justin R. Miller on 5/17/11.
5 -// Copyright 2011, Development Seed, Inc. 5 +// Copyright 2012 MapBox.
6 // All rights reserved. 6 // All rights reserved.
7 // 7 //
8 // Redistribution and use in source and binary forms, with or without 8 // Redistribution and use in source and binary forms, with or without
@@ -15,9 +15,9 @@ @@ -15,9 +15,9 @@
15 // notice, this list of conditions and the following disclaimer in the 15 // notice, this list of conditions and the following disclaimer in the
16 // documentation and/or other materials provided with the distribution. 16 // documentation and/or other materials provided with the distribution.
17 // 17 //
18 -// * Neither the name of Development Seed, Inc., nor the names of its  
19 -// contributors may be used to endorse or promote products derived from  
20 -// this software without specific prior written permission. 18 +// * Neither the name of MapBox, nor the names of its contributors may be
  19 +// used to endorse or promote products derived from this software
  20 +// without specific prior written permission.
21 // 21 //
22 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 22 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
23 // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 23 // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
@@ -31,9 +31,9 @@ @@ -31,9 +31,9 @@
31 // SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 31 // SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 // 32 //
33 33
34 -#import "RMTileStreamSource.h" 34 +#import "RMMapBoxSource.h"
35 35
36 -@interface RMTileStreamSource () 36 +@interface RMMapBoxSource ()
37 37
38 @property (nonatomic, retain) NSDictionary *infoDictionary; 38 @property (nonatomic, retain) NSDictionary *infoDictionary;
39 39
@@ -41,13 +41,34 @@ @@ -41,13 +41,34 @@
41 41
42 #pragma mark - 42 #pragma mark -
43 43
44 -@implementation RMTileStreamSource 44 +@implementation RMMapBoxSource
45 45
46 @synthesize infoDictionary; 46 @synthesize infoDictionary;
47 47
  48 +- (id)init
  49 +{
  50 + return [self initWithReferenceURL:[NSURL URLWithString:@"http://api.tiles.mapbox.com/v2/mapbox.mapbox-streets.json"]];
  51 +}
  52 +
  53 +- (id)initWithTileJSON:(NSString *)tileJSON
  54 +{
  55 + if (self = [super init])
  56 + {
  57 + NSAssert([NSJSONSerialization class], @"JSON serialization not supported by SDK");
  58 +
  59 + infoDictionary = (NSDictionary *)[[NSJSONSerialization JSONObjectWithData:[tileJSON dataUsingEncoding:NSUTF8StringEncoding]
  60 + options:0
  61 + error:nil] retain];
  62 + }
  63 +
  64 + return self;
  65 +}
  66 +
48 - (id)initWithInfo:(NSDictionary *)info 67 - (id)initWithInfo:(NSDictionary *)info
49 { 68 {
50 - if (!(self = [super init])) 69 + WarnDeprecated();
  70 +
  71 + if ( ! (self = [super init]))
51 return nil; 72 return nil;
52 73
53 infoDictionary = [[NSDictionary dictionaryWithDictionary:info] retain]; 74 infoDictionary = [[NSDictionary dictionaryWithDictionary:info] retain];
@@ -57,7 +78,15 @@ @@ -57,7 +78,15 @@
57 78
58 - (id)initWithReferenceURL:(NSURL *)referenceURL 79 - (id)initWithReferenceURL:(NSURL *)referenceURL
59 { 80 {
60 - return [self initWithInfo:[NSDictionary dictionaryWithContentsOfURL:referenceURL]]; 81 + id dataObject;
  82 +
  83 + if ((dataObject = [NSString stringWithContentsOfURL:referenceURL encoding:NSUTF8StringEncoding error:nil]) && dataObject)
  84 + return [self initWithTileJSON:dataObject];
  85 +
  86 + else if ((dataObject = [[[NSDictionary alloc] initWithContentsOfURL:referenceURL] autorelease]) && dataObject)
  87 + return [self initWithInfo:dataObject];
  88 +
  89 + return nil;
61 } 90 }
62 91
63 - (void)dealloc 92 - (void)dealloc
@@ -74,9 +103,18 @@ @@ -74,9 +103,18 @@
74 // 103 //
75 NSInteger zoom = tile.zoom; 104 NSInteger zoom = tile.zoom;
76 NSInteger x = tile.x; 105 NSInteger x = tile.x;
77 - NSInteger y = pow(2, zoom) - tile.y - 1; 106 + NSInteger y = tile.y;
  107 +
  108 + if ([self.infoDictionary objectForKey:@"scheme"] && [[self.infoDictionary objectForKey:@"scheme"] isEqual:@"tms"])
  109 + y = pow(2, zoom) - tile.y - 1;
78 110
79 - NSString *tileURLString = [self.infoDictionary objectForKey:@"tileURL"]; 111 + NSString *tileURLString;
  112 +
  113 + if ([self.infoDictionary objectForKey:@"tiles"])
  114 + tileURLString = [[self.infoDictionary objectForKey:@"tiles"] objectAtIndex:0];
  115 +
  116 + else
  117 + tileURLString = [self.infoDictionary objectForKey:@"tileURL"];
80 118
81 tileURLString = [tileURLString stringByReplacingOccurrencesOfString:@"{z}" withString:[[NSNumber numberWithInteger:zoom] stringValue]]; 119 tileURLString = [tileURLString stringByReplacingOccurrencesOfString:@"{z}" withString:[[NSNumber numberWithInteger:zoom] stringValue]];
82 tileURLString = [tileURLString stringByReplacingOccurrencesOfString:@"{x}" withString:[[NSNumber numberWithInteger:x] stringValue]]; 120 tileURLString = [tileURLString stringByReplacingOccurrencesOfString:@"{x}" withString:[[NSNumber numberWithInteger:x] stringValue]];
@@ -97,7 +135,15 @@ @@ -97,7 +135,15 @@
97 135
98 - (RMSphericalTrapezium)latitudeLongitudeBoundingBox 136 - (RMSphericalTrapezium)latitudeLongitudeBoundingBox
99 { 137 {
100 - NSArray *parts = [[self.infoDictionary objectForKey:@"bounds"] componentsSeparatedByString:@","]; 138 + id bounds = [self.infoDictionary objectForKey:@"bounds"];
  139 +
  140 + NSArray *parts;
  141 +
  142 + if ([bounds isKindOfClass:[NSArray class]])
  143 + parts = bounds;
  144 +
  145 + else
  146 + parts = [bounds componentsSeparatedByString:@","];
101 147
102 if ([parts count] == 4) 148 if ([parts count] == 4)
103 { 149 {
@@ -115,13 +161,13 @@ @@ -115,13 +161,13 @@
115 return bounds; 161 return bounds;
116 } 162 }
117 163
118 - return kTileStreamDefaultLatLonBoundingBox; 164 + return kMapBoxDefaultLatLonBoundingBox;
119 } 165 }
120 166
121 - (BOOL)coversFullWorld 167 - (BOOL)coversFullWorld
122 { 168 {
123 RMSphericalTrapezium ownBounds = [self latitudeLongitudeBoundingBox]; 169 RMSphericalTrapezium ownBounds = [self latitudeLongitudeBoundingBox];
124 - RMSphericalTrapezium defaultBounds = kTileStreamDefaultLatLonBoundingBox; 170 + RMSphericalTrapezium defaultBounds = kMapBoxDefaultLatLonBoundingBox;
125 171
126 if (ownBounds.southWest.longitude <= defaultBounds.southWest.longitude + 10 && 172 if (ownBounds.southWest.longitude <= defaultBounds.southWest.longitude + 10 &&
127 ownBounds.northEast.longitude >= defaultBounds.northEast.longitude - 10) 173 ownBounds.northEast.longitude >= defaultBounds.northEast.longitude - 10)
@@ -137,7 +183,7 @@ @@ -137,7 +183,7 @@
137 183
138 - (NSString *)uniqueTilecacheKey 184 - (NSString *)uniqueTilecacheKey
139 { 185 {
140 - return [NSString stringWithFormat:@"%@-%@", [self.infoDictionary objectForKey:@"id"], [self.infoDictionary objectForKey:@"version"]]; 186 + return [NSString stringWithFormat:@"MapBox-%@-%@", [self.infoDictionary objectForKey:@"id"], [self.infoDictionary objectForKey:@"version"]];
141 } 187 }
142 188
143 - (NSString *)shortName 189 - (NSString *)shortName
@@ -79,10 +79,9 @@ @@ -79,10 +79,9 @@
79 [super dealloc]; 79 [super dealloc];
80 } 80 }
81 81
82 -- (void)setNeedsDisplay 82 +- (void)didMoveToWindow
83 { 83 {
84 self.contentScaleFactor = 1.0f; 84 self.contentScaleFactor = 1.0f;
85 - [super setNeedsDisplay];  
86 } 85 }
87 86
88 - (void)drawRect:(CGRect)rect 87 - (void)drawRect:(CGRect)rect
@@ -68,6 +68,8 @@ @@ -68,6 +68,8 @@
68 - (void)correctPositionOfAllAnnotations; 68 - (void)correctPositionOfAllAnnotations;
69 - (void)correctPositionOfAllAnnotationsIncludingInvisibles:(BOOL)correctAllLayers wasZoom:(BOOL)wasZoom; 69 - (void)correctPositionOfAllAnnotationsIncludingInvisibles:(BOOL)correctAllLayers wasZoom:(BOOL)wasZoom;
70 70
  71 +- (void)correctMinZoomScaleForBoundingMask;
  72 +
71 @end 73 @end
72 74
73 #pragma mark - 75 #pragma mark -
@@ -255,6 +257,7 @@ @@ -255,6 +257,7 @@
255 mapScrollView.frame = bounds; 257 mapScrollView.frame = bounds;
256 overlayView.frame = bounds; 258 overlayView.frame = bounds;
257 [self correctPositionOfAllAnnotations]; 259 [self correctPositionOfAllAnnotations];
  260 + [self correctMinZoomScaleForBoundingMask];
258 } 261 }
259 } 262 }
260 263
@@ -535,6 +538,28 @@ @@ -535,6 +538,28 @@
535 #pragma mark - 538 #pragma mark -
536 #pragma mark Zoom 539 #pragma mark Zoom
537 540
  541 +- (void)setBoundingMask:(NSUInteger)mask
  542 +{
  543 + boundingMask = mask;
  544 +
  545 + [self correctMinZoomScaleForBoundingMask];
  546 +}
  547 +
  548 +- (void)correctMinZoomScaleForBoundingMask
  549 +{
  550 + if (self.boundingMask != RMMapNoMinBound)
  551 + {
  552 + CGFloat newMinZoomScale = (self.boundingMask == RMMapMinWidthBound ? self.bounds.size.width : self.bounds.size.height) / ((CATiledLayer *)tiledLayerView.layer).tileSize.width;
  553 +
  554 + if (mapScrollView.minimumZoomScale > 0 && newMinZoomScale > mapScrollView.minimumZoomScale)
  555 + {
  556 + RMLog(@"clamping min zoom of %f to %f due to %@", log2f(mapScrollView.minimumZoomScale), log2f(newMinZoomScale), (self.boundingMask == RMMapMinWidthBound ? @"RMMapMinWidthBound" : @"RMMapMinHeightBound"));
  557 +
  558 + mapScrollView.minimumZoomScale = newMinZoomScale;
  559 + }
  560 + }
  561 +}
  562 +
538 - (RMProjectedRect)projectedBounds 563 - (RMProjectedRect)projectedBounds
539 { 564 {
540 CGPoint bottomLeft = CGPointMake(mapScrollView.contentOffset.x, mapScrollView.contentSize.height - (mapScrollView.contentOffset.y + mapScrollView.bounds.size.height)); 565 CGPoint bottomLeft = CGPointMake(mapScrollView.contentOffset.x, mapScrollView.contentSize.height - (mapScrollView.contentOffset.y + mapScrollView.bounds.size.height));
@@ -1277,6 +1302,8 @@ @@ -1277,6 +1302,8 @@
1277 // RMLog(@"New minZoom:%f", newMinZoom); 1302 // RMLog(@"New minZoom:%f", newMinZoom);
1278 1303
1279 mapScrollView.minimumZoomScale = exp2f(newMinZoom); 1304 mapScrollView.minimumZoomScale = exp2f(newMinZoom);
  1305 +
  1306 + [self correctMinZoomScaleForBoundingMask];
1280 } 1307 }
1281 1308
1282 - (void)setMaxZoom:(float)newMaxZoom 1309 - (void)setMaxZoom:(float)newMaxZoom
@@ -150,8 +150,8 @@ @@ -150,8 +150,8 @@
150 DD2B375614CF8197008DE8CB /* RMMBTilesTileSource.m in Sources */ = {isa = PBXBuildFile; fileRef = DD2B375414CF8197008DE8CB /* RMMBTilesTileSource.m */; }; 150 DD2B375614CF8197008DE8CB /* RMMBTilesTileSource.m in Sources */ = {isa = PBXBuildFile; fileRef = DD2B375414CF8197008DE8CB /* RMMBTilesTileSource.m */; };
151 DD8CDB4A14E0507100B73EB9 /* RMMapQuestOSMSource.h in Headers */ = {isa = PBXBuildFile; fileRef = DD8CDB4814E0507100B73EB9 /* RMMapQuestOSMSource.h */; }; 151 DD8CDB4A14E0507100B73EB9 /* RMMapQuestOSMSource.h in Headers */ = {isa = PBXBuildFile; fileRef = DD8CDB4814E0507100B73EB9 /* RMMapQuestOSMSource.h */; };
152 DD8CDB4B14E0507100B73EB9 /* RMMapQuestOSMSource.m in Sources */ = {isa = PBXBuildFile; fileRef = DD8CDB4914E0507100B73EB9 /* RMMapQuestOSMSource.m */; }; 152 DD8CDB4B14E0507100B73EB9 /* RMMapQuestOSMSource.m in Sources */ = {isa = PBXBuildFile; fileRef = DD8CDB4914E0507100B73EB9 /* RMMapQuestOSMSource.m */; };
153 - DD98B6FA14D76B930092882F /* RMTileStreamSource.h in Headers */ = {isa = PBXBuildFile; fileRef = DD98B6F814D76B930092882F /* RMTileStreamSource.h */; };  
154 - DD98B6FB14D76B930092882F /* RMTileStreamSource.m in Sources */ = {isa = PBXBuildFile; fileRef = DD98B6F914D76B930092882F /* RMTileStreamSource.m */; }; 153 + DD98B6FA14D76B930092882F /* RMMapBoxSource.h in Headers */ = {isa = PBXBuildFile; fileRef = DD98B6F814D76B930092882F /* RMMapBoxSource.h */; };
  154 + DD98B6FB14D76B930092882F /* RMMapBoxSource.m in Sources */ = {isa = PBXBuildFile; fileRef = DD98B6F914D76B930092882F /* RMMapBoxSource.m */; };
155 /* End PBXBuildFile section */ 155 /* End PBXBuildFile section */
156 156
157 /* Begin PBXContainerItemProxy section */ 157 /* Begin PBXContainerItemProxy section */
@@ -301,8 +301,8 @@ @@ -301,8 +301,8 @@
301 DD2B375414CF8197008DE8CB /* RMMBTilesTileSource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RMMBTilesTileSource.m; sourceTree = "<group>"; }; 301 DD2B375414CF8197008DE8CB /* RMMBTilesTileSource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RMMBTilesTileSource.m; sourceTree = "<group>"; };
302 DD8CDB4814E0507100B73EB9 /* RMMapQuestOSMSource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RMMapQuestOSMSource.h; sourceTree = "<group>"; }; 302 DD8CDB4814E0507100B73EB9 /* RMMapQuestOSMSource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RMMapQuestOSMSource.h; sourceTree = "<group>"; };
303 DD8CDB4914E0507100B73EB9 /* RMMapQuestOSMSource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RMMapQuestOSMSource.m; sourceTree = "<group>"; }; 303 DD8CDB4914E0507100B73EB9 /* RMMapQuestOSMSource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RMMapQuestOSMSource.m; sourceTree = "<group>"; };
304 - DD98B6F814D76B930092882F /* RMTileStreamSource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RMTileStreamSource.h; sourceTree = "<group>"; };  
305 - DD98B6F914D76B930092882F /* RMTileStreamSource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RMTileStreamSource.m; sourceTree = "<group>"; }; 304 + DD98B6F814D76B930092882F /* RMMapBoxSource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RMMapBoxSource.h; sourceTree = "<group>"; };
  305 + DD98B6F914D76B930092882F /* RMMapBoxSource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RMMapBoxSource.m; sourceTree = "<group>"; };
306 /* End PBXFileReference section */ 306 /* End PBXFileReference section */
307 307
308 /* Begin PBXFrameworksBuildPhase section */ 308 /* Begin PBXFrameworksBuildPhase section */
@@ -366,8 +366,8 @@ @@ -366,8 +366,8 @@
366 16128CF4148D295300C23C0E /* RMOpenSeaMapSource.m */, 366 16128CF4148D295300C23C0E /* RMOpenSeaMapSource.m */,
367 B83E64ED0E80E73F001663B6 /* RMOpenStreetMapSource.h */, 367 B83E64ED0E80E73F001663B6 /* RMOpenStreetMapSource.h */,
368 B83E64EE0E80E73F001663B6 /* RMOpenStreetMapSource.m */, 368 B83E64EE0E80E73F001663B6 /* RMOpenStreetMapSource.m */,
369 - DD98B6F814D76B930092882F /* RMTileStreamSource.h */,  
370 - DD98B6F914D76B930092882F /* RMTileStreamSource.m */, 369 + DD98B6F814D76B930092882F /* RMMapBoxSource.h */,
  370 + DD98B6F914D76B930092882F /* RMMapBoxSource.m */,
371 ); 371 );
372 name = "Map sources"; 372 name = "Map sources";
373 sourceTree = "<group>"; 373 sourceTree = "<group>";
@@ -666,7 +666,7 @@ @@ -666,7 +666,7 @@
666 DD2B374F14CF814F008DE8CB /* FMDatabasePool.h in Headers */, 666 DD2B374F14CF814F008DE8CB /* FMDatabasePool.h in Headers */,
667 DD2B375114CF814F008DE8CB /* FMDatabaseQueue.h in Headers */, 667 DD2B375114CF814F008DE8CB /* FMDatabaseQueue.h in Headers */,
668 DD2B375514CF8197008DE8CB /* RMMBTilesTileSource.h in Headers */, 668 DD2B375514CF8197008DE8CB /* RMMBTilesTileSource.h in Headers */,
669 - DD98B6FA14D76B930092882F /* RMTileStreamSource.h in Headers */, 669 + DD98B6FA14D76B930092882F /* RMMapBoxSource.h in Headers */,
670 DD8CDB4A14E0507100B73EB9 /* RMMapQuestOSMSource.h in Headers */, 670 DD8CDB4A14E0507100B73EB9 /* RMMapQuestOSMSource.h in Headers */,
671 1607499514E120A100D535F5 /* RMGenericMapSource.h in Headers */, 671 1607499514E120A100D535F5 /* RMGenericMapSource.h in Headers */,
672 16FFF2CB14E3DBF700A170EC /* RMMapQuestOpenAerialSource.h in Headers */, 672 16FFF2CB14E3DBF700A170EC /* RMMapQuestOpenAerialSource.h in Headers */,
@@ -883,7 +883,7 @@ @@ -883,7 +883,7 @@
883 DD2B375014CF814F008DE8CB /* FMDatabasePool.m in Sources */, 883 DD2B375014CF814F008DE8CB /* FMDatabasePool.m in Sources */,
884 DD2B375214CF814F008DE8CB /* FMDatabaseQueue.m in Sources */, 884 DD2B375214CF814F008DE8CB /* FMDatabaseQueue.m in Sources */,
885 DD2B375614CF8197008DE8CB /* RMMBTilesTileSource.m in Sources */, 885 DD2B375614CF8197008DE8CB /* RMMBTilesTileSource.m in Sources */,
886 - DD98B6FB14D76B930092882F /* RMTileStreamSource.m in Sources */, 886 + DD98B6FB14D76B930092882F /* RMMapBoxSource.m in Sources */,
887 DD8CDB4B14E0507100B73EB9 /* RMMapQuestOSMSource.m in Sources */, 887 DD8CDB4B14E0507100B73EB9 /* RMMapQuestOSMSource.m in Sources */,
888 1607499614E120A100D535F5 /* RMGenericMapSource.m in Sources */, 888 1607499614E120A100D535F5 /* RMGenericMapSource.m in Sources */,
889 16FFF2CC14E3DBF700A170EC /* RMMapQuestOpenAerialSource.m in Sources */, 889 16FFF2CC14E3DBF700A170EC /* RMMapQuestOpenAerialSource.m in Sources */,