1
0
forked from MTSR/mapserver
mapserver/server/static/js/overlays/LabelOverlay.js
2019-02-08 18:06:16 +01:00

16 lines
376 B
JavaScript

'use strict';
var LabelOverlay = AbstractIconOverlay.extend({
initialize: function(wsChannel, layerMgr) {
AbstractIconOverlay.prototype.initialize.call(this, wsChannel, layerMgr, "label");
},
getIcon: function(lbl){
return L.divIcon({html: lbl.attributes.text});
},
createPopup: function(lbl){
return "<pre>" + lbl.attributes.text + "</pre>";
}
});