move Linux & OS X to per-map access tokens
This commit is contained in:
@@ -52,8 +52,6 @@ int main(int argc, char *argv[]) {
|
||||
std::stringstream stylejson;
|
||||
stylejson << stylefile.rdbuf();
|
||||
|
||||
llmr::setMapboxAccessToken(mapbox_access_token);
|
||||
|
||||
view = new GLFWView();
|
||||
llmr::Map map(*view);
|
||||
|
||||
@@ -64,6 +62,7 @@ int main(int argc, char *argv[]) {
|
||||
map.setDebug(settings.debug);
|
||||
|
||||
// Load style
|
||||
map.setAccessToken(mapbox_access_token);
|
||||
map.setStyleJSON(stylejson.str());
|
||||
|
||||
int ret = view->run();
|
||||
|
||||
@@ -5,8 +5,6 @@
|
||||
#import <Foundation/Foundation.h>
|
||||
|
||||
int main() {
|
||||
llmr::setMapboxAccessToken(mapbox_access_token);
|
||||
|
||||
GLFWView view;
|
||||
llmr::Map map(view);
|
||||
|
||||
@@ -17,6 +15,7 @@ int main() {
|
||||
map.setDebug(settings.debug);
|
||||
|
||||
// Load style
|
||||
map.setAccessToken(mapbox_access_token);
|
||||
NSString *path = [[NSBundle mainBundle] pathForResource:@"style.min" ofType:@"js"];
|
||||
NSString *json = [NSString stringWithContentsOfFile:path
|
||||
encoding:[NSString defaultCStringEncoding]
|
||||
|
||||
Reference in New Issue
Block a user