1 |
3032
|
perry
|
/*
|
2 |
|
|
License: LGPL as per: http://www.gnu.org/copyleft/lesser.html
|
3 |
4307
|
leinfelder
|
$Id: ZoomIn.js 2956 2007-07-09 12:17:52Z steven $
|
4 |
3032
|
perry
|
*/
|
5 |
|
|
|
6 |
|
|
// Ensure this object's dependancies are loaded.
|
7 |
|
|
mapbuilder.loadScript(baseDir+"/widget/ButtonBase.js");
|
8 |
4307
|
leinfelder
|
mapbuilder.loadScript(baseDir+"/util/openlayers/OpenLayers.js");
|
9 |
3032
|
perry
|
|
10 |
|
|
/**
|
11 |
4307
|
leinfelder
|
* ZoomIn button - zooms in on click or box drag in the map.
|
12 |
3032
|
perry
|
* @constructor
|
13 |
|
|
* @base ButtonBase
|
14 |
4307
|
leinfelder
|
* @author Andreas HOcevar andreas.hocevarATgmail.com
|
15 |
3032
|
perry
|
* @param widgetNode The widget node from the Config XML file.
|
16 |
4307
|
leinfelder
|
* @param model The model for this widget
|
17 |
3032
|
perry
|
*/
|
18 |
|
|
function ZoomIn(widgetNode, model) {
|
19 |
|
|
// Extend ButtonBase
|
20 |
|
|
ButtonBase.apply(this, new Array(widgetNode, model));
|
21 |
|
|
|
22 |
4307
|
leinfelder
|
this.cursor = 'crosshair';
|
23 |
3032
|
perry
|
|
24 |
4307
|
leinfelder
|
this.createControl = function() {
|
25 |
|
|
return OpenLayers.Control.ZoomBox;
|
26 |
3032
|
perry
|
}
|
27 |
|
|
}
|