Compare commits

..

5 Commits

Author SHA1 Message Date
Tim Schaub
288a284fdd Changes for v4.3.3 2017-09-15 06:15:49 -06:00
Andreas Hocevar
a5b3da1f8a Revert "Merge pull request #7098 from ahocevar/no-math-round"
This reverts commit 5b75666755, reversing
changes made to ff9ef481db.
2017-09-15 06:13:18 -06:00
Tim Schaub
6ed8a9229f Update package version to 4.3.2 2017-08-31 16:25:07 -06:00
Tim Schaub
60b2290add Changelog for v4.3.2 2017-08-31 16:24:14 -06:00
Frederic Junod
afcc86558c Export ol.Sphere.getLength and ol.Sphere.getArea 2017-08-31 16:20:15 -06:00
6 changed files with 22 additions and 6 deletions

7
changelog/v4.3.2.md Normal file
View File

@@ -0,0 +1,7 @@
# 4.3.2
The v4.3.2 release includes a single fix.
## Fixes
* [#7140](https://github.com/openlayers/openlayers/pull/7140) - Export ol.Sphere.getLength and ol.Sphere.getArea ([@fredj](https://github.com/fredj))

7
changelog/v4.3.3.md Normal file
View File

@@ -0,0 +1,7 @@
# 4.3.2
The v4.3.3 reverts the fractional pixel positioning of overlays.
## Fixes
* [#7258](https://github.com/openlayers/openlayers/pull/7258) - Revert changes made in #7098 ([@ahocevar](https://github.com/ahocevar))

View File

@@ -1,6 +1,6 @@
{
"name": "openlayers",
"version": "4.3.1",
"version": "4.3.3",
"description": "Build tools and sources for developing OpenLayers based mapping applications",
"keywords": [
"map",

View File

@@ -1,6 +1,6 @@
{
"name": "ol",
"version": "4.3.1",
"version": "4.3.3",
"description": "OpenLayers as ES2015 modules",
"main": "index.js",
"module": "index.js",

View File

@@ -475,7 +475,7 @@ ol.Overlay.prototype.updateRenderedPosition = function(pixel, mapSize) {
if (this.rendered_.left_ !== '') {
this.rendered_.left_ = style.left = '';
}
var right = (mapSize[0] - pixel[0] - offsetX) + 'px';
var right = Math.round(mapSize[0] - pixel[0] - offsetX) + 'px';
if (this.rendered_.right_ != right) {
this.rendered_.right_ = style.right = right;
}
@@ -488,7 +488,7 @@ ol.Overlay.prototype.updateRenderedPosition = function(pixel, mapSize) {
positioning == ol.OverlayPositioning.TOP_CENTER) {
offsetX -= this.element_.offsetWidth / 2;
}
var left = (pixel[0] + offsetX) + 'px';
var left = Math.round(pixel[0] + offsetX) + 'px';
if (this.rendered_.left_ != left) {
this.rendered_.left_ = style.left = left;
}
@@ -499,7 +499,7 @@ ol.Overlay.prototype.updateRenderedPosition = function(pixel, mapSize) {
if (this.rendered_.top_ !== '') {
this.rendered_.top_ = style.top = '';
}
var bottom = (mapSize[1] - pixel[1] - offsetY) + 'px';
var bottom = Math.round(mapSize[1] - pixel[1] - offsetY) + 'px';
if (this.rendered_.bottom_ != bottom) {
this.rendered_.bottom_ = style.bottom = bottom;
}
@@ -512,7 +512,7 @@ ol.Overlay.prototype.updateRenderedPosition = function(pixel, mapSize) {
positioning == ol.OverlayPositioning.CENTER_RIGHT) {
offsetY -= this.element_.offsetHeight / 2;
}
var top = (pixel[1] + offsetY) + 'px';
var top = Math.round(pixel[1] + offsetY) + 'px';
if (this.rendered_.top_ != top) {
this.rendered_.top_ = style.top = top;
}

View File

@@ -110,6 +110,7 @@ ol.Sphere.DEFAULT_RADIUS = 6371008.8;
* calculation. By default, geometries are assumed to be in 'EPSG:3857'.
* You can change this by providing a `projection` option.
* @return {number} The spherical length (in meters).
* @api
*/
ol.Sphere.getLength = function(geometry, opt_options) {
var options = opt_options || {};
@@ -205,6 +206,7 @@ ol.Sphere.getDistance_ = function(c1, c2, radius) {
* calculation. By default, geometries are assumed to be in 'EPSG:3857'.
* You can change this by providing a `projection` option.
* @return {number} The spherical area (in square meters).
* @api
*/
ol.Sphere.getArea = function(geometry, opt_options) {
var options = opt_options || {};