diff options
author | Jonas Danielsson <jonas@threetimestwo.org> | 2016-08-16 21:41:39 +0200 |
---|---|---|
committer | Jonas Danielsson <jonas@threetimestwo.org> | 2016-08-22 20:11:49 +0200 |
commit | acc70208adaaef2ac1296bbea8a3a9f622088809 (patch) | |
tree | 68c52ca39fcd980890357578bf2866a48b77ccc0 | |
parent | 6a6a17ecb8ff83543891375ebd591d197830869e (diff) | |
download | gnome-maps-acc70208adaaef2ac1296bbea8a3a9f622088809.tar.gz |
Add print tile service
Use the print style from the service.json file for the print
source. Right now it is same as street style. But gives us the
possibility of having a special print style later.
https://bugzilla.gnome.org/show_bug.cgi?id=769352
-rw-r--r-- | src/mapSource.js | 4 | ||||
-rw-r--r-- | src/printLayout.js | 2 |
2 files changed, 5 insertions, 1 deletions
diff --git a/src/mapSource.js b/src/mapSource.js index d7b82c45..f7f8df42 100644 --- a/src/mapSource.js +++ b/src/mapSource.js @@ -150,3 +150,7 @@ function createAerialSource() { function createStreetSource() { return _createCachedSource(_getTileService().street); } + +function createPrintSource() { + return _createCachedSource(_getTileService().print); +} diff --git a/src/printLayout.js b/src/printLayout.js index 64dd6c77..45868e9a 100644 --- a/src/printLayout.js +++ b/src/printLayout.js @@ -149,7 +149,7 @@ const PrintLayout = new Lang.Class({ let pageNum = this.numPages - 1; let x = this._cursorX; let y = this._cursorY; - let mapSource = MapSource.createStreetSource(); + let mapSource = MapSource.createPrintSource(); let locations = []; let markerLayer = new Champlain.MarkerLayer(); let view = new Champlain.View({ width: width, |