/*  dans un fichier dhtmlCursor.js */

Map.prototype.CursorLocation = function(aDisplay) {
/*
  this.resetMapEventHandlers();
  this.setCurrentLayer('CursorLocation');
  this.getDisplay(aDisplay).setTool('draw.point');

  this.onNewFeature = function(aFeature) {
    this.onToolUnset();
  };
  this.onFeatureInput = this.onFeatureChange = function(aFeature) {
    // mettre à jour le champ de formulaire
    // avec les valeurs de coordonnées
    CartoWeb.trigger('CursorLocation.computeCoords', "doSubmit()");
    //alert('cartoweb called for trigger');
  };
  this.onToolUnset = function() {
    this.getDisplay(aDisplay).clearLayer('CursorLocation');
    this.onCancel();
  };
  this.onCancel = function() {
  };
  */
  
  // shows CursorLocation Layer only if not already visible
  if (document.getElementById('CursorLocationID').style.display == 'none' || 
      document.getElementById('CursorLocationID').style.display == '') {
  	showLayer("CursorLocationID");
  }
  this.selectionPoint(aDisplay, 'CursorLocation.computeCoords');
};
