Add className option to ol.control.MousePosition

This commit is contained in:
Tom Payne
2013-05-07 16:18:05 +02:00
parent 525d5c5337
commit f31a4f8549
2 changed files with 5 additions and 1 deletions

View File

@@ -137,6 +137,7 @@
/**
* @typedef {Object} ol.control.MousePositionOptions
* @property {string|undefined} className Class name.
* @property {ol.CoordinateFormatType|undefined} coordinateFormat Coordinate
* format.
* @property {ol.Map|undefined} map Map.

View File

@@ -27,8 +27,11 @@ ol.control.MousePosition = function(opt_options) {
var options = goog.isDef(opt_options) ? opt_options : {};
var className = goog.isDef(options.className) ?
options.className : 'ol-mouseposition';
var element = goog.dom.createDom(goog.dom.TagName.DIV, {
'class': 'ol-mouseposition'
'class': className
});
goog.base(this, {