Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Commit

Permalink
[glfw] allow loading mapbox:// style URLs via CLI
Browse files Browse the repository at this point in the history
  • Loading branch information
kkaefer committed Sep 21, 2017
1 parent f659aa4 commit b91d967
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion platform/glfw/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ int main(int argc, char *argv[]) {
benchmark = true;
break;
case 's':
style = std::string("asset://") + std::string(optarg);
style = std::string(optarg);
break;
case 'x':
longitude = atof(optarg);
Expand Down Expand Up @@ -124,6 +124,10 @@ int main(int argc, char *argv[]) {

backend.setMap(&map);

if (style.find("://") == std::string::npos) {
style = std::string("file://") + style;
}

// Load settings
mbgl::Settings_JSON settings;

Expand Down

0 comments on commit b91d967

Please sign in to comment.