Merge pull request #693 from twpayne/class-name

Add className option to control options
This commit is contained in:
Tom Payne
2013-05-08 05:35:37 -07:00
11 changed files with 46 additions and 61 deletions

View File

@@ -8,12 +8,6 @@
<link rel="stylesheet" href="../resources/layout.css" type="text/css">
<link rel="stylesheet" href="../resources/bootstrap/css/bootstrap-responsive.min.css" type="text/css">
<title>Mouse position example</title>
<style type="text/css">
/* Nullify the default .ol-mouseposition rule */
#mouse-position .ol-mouseposition {
position: static;
}
</style>
</head>
<body>

View File

@@ -13,8 +13,9 @@ var map = new ol.Map({
new ol.control.MousePosition({
coordinateFormat: ol.coordinate.toStringHDMS,
projection: 'EPSG:4326',
// comment the following line to have the mouse position
// comment the following two lines to have the mouse position
// be placed within the map.
className: 'custom-mouse-position',
target: document.getElementById('mouse-position'),
undefinedHTML: '&nbsp;'
})