diff --git a/predict/index.php b/predict/index.php index 35fd708..d17078d 100644 --- a/predict/index.php +++ b/predict/index.php @@ -143,8 +143,8 @@ google.load("jqueryui", "1.8.1");

Written by Jon Sowman and Adam Greig for CUSF. Credit also to Rich Wareham for work on the predictor. Some parts of code taken from old landing prediction software, credit to Rob Anderson, Fergus Noble and Ed Moore. -
- Minor credit to Robert Harrison for integrating the NOTAM and airspace KML from www.notaminfo.com with kind permission from David Massie. +

+ Minor credit to Robert Harrison for integrating the NOTAM and airspace KML from www.notaminfo.com with kind permission from author David Massie.

No guarantee is given for the accuracy, precision or reliability of the data produced by this software, and you use it entirely at your own risk. For more information, see #highaltitude on irc.freenode.net. @@ -291,99 +291,16 @@ google.load("jqueryui", "1.8.1");
Advanced NOTAM & Airspace Settings -
+

+ NB This is not yet functional !!! - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +
Payload Mass (g)ANDBalloon Mass (g)
- - - -
  
THEN
Target Burst Altitude (m)ORTarget Ascent Rate (m/s)
- - - - -
  
Burst Altitude:33000 mAscent Rate:2.33 m/s
Time to Burst:238 minNeck Lift:1733 g
Launch Volume:2.66 - m32660 L93.9 - ft3 +
NOTAM details
Show NOTAMs
Airspace Details
Show Default airspace
Show class A airspace
Show class D airspace
Show class E airspace
Show class G airspace
Show prohibited airspace
Show restricted airspace
Show MATZs
Show danger areas
Show offshore/NOTAMed danger areas
Show hazards (HIRTA/AIAA etc)
+ -
- - -

@@ -510,7 +427,7 @@ google.load("jqueryui", "1.8.1"); Display UK NOTAMS & Airspace: - + Advanced diff --git a/predict/js/pred/pred-config.js b/predict/js/pred/pred-config.js index 8721982..276c0bd 100644 --- a/predict/js/pred/pred-config.js +++ b/predict/js/pred/pred-config.js @@ -17,6 +17,7 @@ var ajaxEventHandle; var current_uuid = '0'; var map; +var kmlLayer = null; var map_items = []; var launch_img = "images/target-1-sm.png"; var land_img = "images/target-8-sm.png"; diff --git a/predict/js/pred/pred-event.js b/predict/js/pred/pred-event.js index c3543ff..a7688de 100644 --- a/predict/js/pred/pred-event.js +++ b/predict/js/pred/pred-event.js @@ -68,43 +68,25 @@ function EH_BurstCalc() { } function EH_NOTAMSettings() { - // Activate the "use burst calc" links + // Activate the checkbox + $("#notam-display").click(function() { + if (document.modelForm.notams.checked){ + if (kmlLayer == null) kmlLayer = new google.maps.KmlLayer('http://www.habhub.org/kml_testing/notam_and_restrict.kml', {preserveViewport: true}); + kmlLayer.setMap(map); + } + else { + kmlLayer.setMap(null); + } + }); + // Activate the "notam settings" links $("#notam-settings-show").click(function() { - alert("RJH"); $("#notam-settings-wrapper").show(); }); - $("#burst-calc-show").hover( - function() { - $("#ascent,#burst").css("background-color", "#AACCFF"); - }, - function() { - $("#ascent,#burst").css("background-color", "#FFFFFF"); - }); - $("#burst-calc-use").click(function() { - // Write the ascent rate and burst altitude to the launch card - $("#ascent").val($("#ar").html()); - $("#burst").val($("#ba").html()); - $("#burst-calc-wrapper").hide(); - }); - $("#burst-calc-close").click(function() { - // Close the burst calc without doing anything - $("#burst-calc-wrapper").hide(); + $("#notam-settings-close").click(function() { + // Close the notam settings doing anything + $("#notam-settings-wrapper").hide(); $("#modelForm").show(); }); - $("#burst-calc-advanced-show").click(function() { - // Show the burst calculator constants - // We use a callback function to fade in the new content to make - // sure the old content has gone, in order to create a smooth effect - $("#burst-calc").fadeOut('fast', function() { - $("#burst-calc-constants").fadeIn(); - }); - }); - $("#burst-calc-advanced-hide").click(function() { - // Show the burst calculator constants - $("#burst-calc-constants").fadeOut('fast', function() { - $("#burst-calc").fadeIn(); - }); - }); } function EH_LaunchCard() { diff --git a/predict/js/pred/pred-map.js b/predict/js/pred/pred-map.js index 8e9b72b..4776b00 100644 --- a/predict/js/pred/pred-map.js +++ b/predict/js/pred/pred-map.js @@ -23,8 +23,6 @@ function initMap(centre_lat, centre_lon, zoom_level) { center: latlng }; map = new google.maps.Map(document.getElementById("map_canvas"), myOptions); - var ctaLayer = new google.maps.KmlLayer('http://www.habhub.org/kml_testing/notam_and_restrict.kml', {preserveViewport: true}); - ctaLayer.setMap(map); } // Enable or disable user control of the map canvas, including scrolling,