|
Community Map Builder 02 Dec 2005 | |||||||
| PREV NEXT | FRAMES NO FRAMES | |||||||
No overview generated for 'MouseClickHandler.js'
| Class Summary | |
| MouseClickHandler | |
/* Author: Cameron Shorter cameronATshorter.net License: LGPL as per: http://www.gnu.org/copyleft/lesser.html $Id: MouseClickHandler.js,v 1.9 2005/09/20 02:40:09 madair1 Exp $ */ // Ensure this object's dependancies are loaded. mapbuilder.loadScript(baseDir+"/tool/ToolBase.js"); /** * Tool which processes mouse clicks on a widget. * The tool must be enabled before use by calling tool.enable(true); * This tool registers mouse event listeners on the parent widget. * This tool works entirely in pixel/line coordinate space and knows nothing * about geography. * @constructor * @base ToolBase * @param toolNode The node for this tool from the configuration document. * @param model The model object that contains this tool */ function MouseClickHandler(toolNode, model) { ToolBase.apply(this, new Array(toolNode, model)); /** * Process a mouse click action. * @param objRef Pointer to this MouseClickHandler object. * @param targetNode The node for the enclosing HTML tag for this widget. */ this.clickHandler = function(objRef,targetNode) { objRef.model.setParam("clickPoint", targetNode.evpl); } model.addListener('mouseup',this.clickHandler,this); }
|
Community Map Builder 02 Dec 2005 | |||||||
| PREV NEXT | FRAMES NO FRAMES | |||||||