1 |
3032
|
perry
|
/*
|
2 |
|
|
Author: Tom Kralidis
|
3 |
|
|
License: LGPL as per: http://www.gnu.org/copyleft/lesser.html
|
4 |
|
|
|
5 |
|
|
$Id$
|
6 |
|
|
*/
|
7 |
|
|
|
8 |
|
|
// Ensure this object's dependancies are loaded.
|
9 |
|
|
mapbuilder.loadScript(baseDir+"/widget/WidgetBase.js");
|
10 |
|
|
|
11 |
|
|
/**
|
12 |
|
|
* Widget to display predefined locations (as per schema at lib/model/schemas/locations.xsd)
|
13 |
|
|
* into a HTML select box. Changing a location will set the AOI of the targetModel.
|
14 |
|
|
* TBD: projection coordinate conversion still to be implemented.
|
15 |
|
|
* @constructor
|
16 |
|
|
* @base WidgetBase
|
17 |
|
|
* @param widgetNode This widget's object node from the configuration document.
|
18 |
|
|
* @param model The model that this widget is a view of.
|
19 |
|
|
*/
|
20 |
|
|
|
21 |
|
|
|
22 |
|
|
function ObjectList(widgetNode, model) {
|
23 |
|
|
WidgetBaseXSL.apply(this,new Array(widgetNode, model));
|
24 |
|
|
|
25 |
|
|
/**
|
26 |
|
|
* Change the AOI coordinates from select box choice of prefined locations
|
27 |
|
|
* @param bbox the bbox value of the location keyword chosen
|
28 |
|
|
* @param targetModel the model on which to set the AOI
|
29 |
|
|
*/
|
30 |
|
|
this.showDetails = function(objectType) {
|
31 |
|
|
var details = config.objects.objectDetails;
|
32 |
|
|
details.stylesheet.setParameter("objectType",objectType);
|
33 |
|
|
details.paint(details);
|
34 |
|
|
}
|
35 |
|
|
}
|