Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update OpenLayers to version 5.3.0 #675

Merged
merged 2 commits into from
Nov 7, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
* Changes
* CanvasPattern and CanvasGradient styles are now handled for polygons.
* Port to Cesium 1.51.
* Port to OpenLayers 5.3.0.

# v 2.4 - 2018-10-01

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
"jsdoc": "3.5.5",
"ls": "0.2.1",
"nomnom": "1.8.1",
"ol": "5.2.0",
"ol": "5.3.0",
"proj4": "2.4.4",
"temp": "0.8.3",
"webpack": "^4.20.2",
Expand Down
8 changes: 4 additions & 4 deletions src/olcs/FeatureConverter.js
Original file line number Diff line number Diff line change
Expand Up @@ -718,10 +718,10 @@ class FeatureConverter {
});

if (imageStyle instanceof olStyleIcon) {
bbOptions.pixelOffset = new Cesium.Cartesian2(
image.width / 2 - imageStyle.getAnchor()[0],
image.height / 2 - imageStyle.getAnchor()[1]
);
const anchor = imageStyle.getAnchor();
if (anchor) {
bbOptions.pixelOffset = new Cesium.Cartesian2(image.width / 2 - anchor[0], image.height / 2 - anchor[1]);
}
}

const bb = this.csAddBillboard(billboards, bbOptions, layer, feature, olGeometry, style);
Expand Down