add browser help links for map features
[potlatch2.git] / net / systemeD / potlatch2 / TagViewer.mxml
index 5fc43f4a6ff6f09a79daa20136912c27929adaf9..d47478cb55a3fd0b0bbe7298269aa6106634d9f9 100644 (file)
@@ -68,6 +68,7 @@
       import mx.core.*;
       import mx.managers.PopUpManager;
       import flash.geom.Point;
+      import flash.net.*;
       
       private var mapFeatures:MapFeatures;
       private var selectedEntity:Entity;
           popupChange.label = feature.name;
           setLimitTypes(entity);
           tw.setSelectedFeature(feature);
+          helpLabel.visible = feature.hasHelpURL();
       }
       
       private function setLimitTypes(entity:Entity):void {
           popupChange.label = "unknown";
           setLimitTypes(entity);
           tw.setSelectedFeature(null);
+          helpLabel.visible = false;
       }
 
       private function initialiseEditors():void {
 
       public function openDescription():void {
           trace("open description here");
+          if ( feature != null && feature.hasHelpURL() )
+              navigateToURL(new URLRequest(feature.helpURL), "potlatch_help");
       }
 
       public function addNewTag():void {