Use string instead of ol.OverlayPositioning enum in examples

This commit is contained in:
Tom Payne
2014-02-06 19:25:22 +01:00
parent dc2bb57d18
commit 9af436b5a0
3 changed files with 3 additions and 6 deletions

View File

@@ -5,7 +5,6 @@
goog.require('ol.Geolocation');
goog.require('ol.Map');
goog.require('ol.Overlay');
goog.require('ol.OverlayPositioning');
goog.require('ol.RendererHints');
goog.require('ol.View2D');
goog.require('ol.dom.Input');
@@ -45,7 +44,7 @@ geolocation.on('propertychange', function() {
var marker = new ol.Overlay({
element: /** @type {Element} */ ($('<i/>').addClass('icon-flag').get(0)),
positioning: ol.OverlayPositioning.BOTTOM_LEFT,
positioning: 'bottom-left',
stopEvent: false
});
map.addOverlay(marker);

View File

@@ -1,6 +1,5 @@
goog.require('ol.Map');
goog.require('ol.Overlay');
goog.require('ol.OverlayPositioning');
goog.require('ol.View2D');
goog.require('ol.layer.Tile');
goog.require('ol.layer.Vector');
@@ -62,7 +61,7 @@ var element = document.getElementById('popup');
var popup = new ol.Overlay({
element: element,
positioning: ol.OverlayPositioning.BOTTOM_CENTER,
positioning: 'bottom-center',
stopEvent: false
});
map.addOverlay(popup);

View File

@@ -1,6 +1,5 @@
goog.require('ol.Map');
goog.require('ol.Overlay');
goog.require('ol.OverlayPositioning');
goog.require('ol.RendererHints');
goog.require('ol.View2D');
goog.require('ol.coordinate');
@@ -28,7 +27,7 @@ var pos = ol.proj.transform([16.3725, 48.208889], 'EPSG:4326', 'EPSG:3857');
// Vienna marker
var marker = new ol.Overlay({
position: pos,
positioning: ol.OverlayPositioning.CENTER_CENTER,
positioning: 'center-center',
element: document.getElementById('marker'),
stopEvent: false
});