Merge pull request #2 from mattburchett/swapbutton
Adding a swap button to the route planner
This commit is contained in:
commit
19297d2614
@ -70,6 +70,7 @@
|
||||
<select id="pointb" name="Point_B">
|
||||
<!-- Options will generated in code -->
|
||||
</select>
|
||||
<button id="swapab" class="btn">Swap</button>
|
||||
<br /> <br />
|
||||
<label for="speed">Travel Speed</label> <br />
|
||||
<input type="text" id="speed" value="14"> <br />
|
||||
|
@ -39,6 +39,11 @@ $(document).ready(function() {
|
||||
var stop=$('#route_output :selected').parent().attr('label');
|
||||
zoomfocus(stop);
|
||||
});
|
||||
$('#swapab').click(function() {
|
||||
var swap=$('#pointa').val();
|
||||
$("#pointa").val($("#pointb").val());
|
||||
$("#pointb").val(swap);
|
||||
});
|
||||
$('#calctnd').click(function() {
|
||||
|
||||
removeEntity('arrow');
|
||||
|
Loading…
Reference in New Issue
Block a user