Merge pull request #1412 from fredj/vector-api-hidpi-cleanup

[vector-api] hidpi cleanup
This commit is contained in:
Éric Lemoine
2013-12-20 07:51:10 -08:00
6 changed files with 13 additions and 9 deletions

View File

@@ -0,0 +1,4 @@
@exportSymbol ol.source.wms.ServerType
@exportProperty ol.source.wms.ServerType.GEOSERVER
@exportProperty ol.source.wms.ServerType.MAPSERVER
@exportProperty ol.source.wms.ServerType.QGIS

View File

@@ -10,8 +10,8 @@ goog.require('goog.uri.utils');
* @enum {string}
*/
ol.source.wms.ServerType = {
MAPSERVER: 'mapserver',
GEOSERVER: 'geoserver',
MAPSERVER: 'mapserver',
QGIS: 'qgis'
};
@@ -63,7 +63,7 @@ ol.source.wms.getDpiParam = function(serverType, pixelRatio) {
if (serverType == ol.source.wms.ServerType.MAPSERVER) {
param['MAP_RESOLUTION'] = 90 * pixelRatio;
} else if (serverType == ol.source.wms.ServerType.GEOSERVER) {
param['FORMAT_OPTION'] = 'dpi:' + 90 * pixelRatio;
param['FORMAT_OPTIONS'] = 'dpi:' + 90 * pixelRatio;
} else if (serverType == ol.source.wms.ServerType.QGIS) {
param['DPI'] = 90 * pixelRatio;
} else {