Merge remote-tracking branch 'openlayers/master' into vector-api
This commit is contained in:
2
build.py
2
build.py
@@ -159,7 +159,7 @@ def report_sizes(t):
|
|||||||
gzipfile.close()
|
gzipfile.close()
|
||||||
rawsize = os.stat(t.name).st_size
|
rawsize = os.stat(t.name).st_size
|
||||||
gzipsize = len(stringio.getvalue())
|
gzipsize = len(stringio.getvalue())
|
||||||
savings = '{:.2%}'.format((rawsize - gzipsize)/float(rawsize))
|
savings = '{0:.2%}'.format((rawsize - gzipsize)/float(rawsize))
|
||||||
t.info('uncompressed: %8d bytes', rawsize)
|
t.info('uncompressed: %8d bytes', rawsize)
|
||||||
t.info(' compressed: %8d bytes, (saved %s)', gzipsize, savings)
|
t.info(' compressed: %8d bytes, (saved %s)', gzipsize, savings)
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
@exportSymbol ol.proj.Projection
|
@exportSymbol ol.proj.Projection
|
||||||
@exportProperty ol.proj.Projection.prototype.getCode
|
@exportProperty ol.proj.Projection.prototype.getCode
|
||||||
@exportProperty ol.proj.Projection.prototype.getExtent
|
@exportProperty ol.proj.Projection.prototype.getExtent
|
||||||
|
@exportProperty ol.proj.Projection.prototype.getUnits
|
||||||
|
|
||||||
@exportSymbol ol.proj.Units
|
@exportSymbol ol.proj.Units
|
||||||
@exportProperty ol.proj.Units.DEGREES
|
@exportProperty ol.proj.Units.DEGREES
|
||||||
|
|||||||
@@ -416,10 +416,12 @@ ol.View2D.prototype.getZoom = function() {
|
|||||||
* @todo stability experimental
|
* @todo stability experimental
|
||||||
*/
|
*/
|
||||||
ol.View2D.prototype.fitExtent = function(extent, size) {
|
ol.View2D.prototype.fitExtent = function(extent, size) {
|
||||||
|
if (!ol.extent.isEmpty(extent)) {
|
||||||
this.setCenter(ol.extent.getCenter(extent));
|
this.setCenter(ol.extent.getCenter(extent));
|
||||||
var resolution = this.getResolutionForExtent(extent, size);
|
var resolution = this.getResolutionForExtent(extent, size);
|
||||||
resolution = this.constrainResolution(resolution, 0, 0);
|
resolution = this.constrainResolution(resolution, 0, 0);
|
||||||
this.setResolution(resolution);
|
this.setResolution(resolution);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user