Permalink
Browse files

Separated into src/ and dist/

+ added grunt task to optionally compile without elevation (grunt no-elevation)
  • Loading branch information...
manuelbieh committed Oct 18, 2012
1 parent a3772fb commit 6718a9d48dbe64be8a6f0a0ed2d1407cb4668401
Showing with 841 additions and 49 deletions.
  1. +1 −1 demo/index.html
  2. +5 −4 { → dist}/geolib.js
  3. +11 −0 dist/geolib.min.js
  4. +0 −11 geolib.min.js
  5. +13 −7 grunt.js
  6. 0 { → src}/geolib.elevation.js
  7. +809 −0 src/geolib.js
  8. +0 −24 tests/geolib.min.test.html
  9. +2 −2 tests/geolib.test.html
View
@@ -9,7 +9,7 @@
<meta charset="utf-8" />
-<script src="../geolib.js"></script>
+<script src="../dist/geolib.js"></script>
<script>
$(function() {
@@ -5,7 +5,7 @@
*
* @author Manuel Bieh
* @url http://www.manuelbieh.com/
-* @version 1.2.0
+* @version 1.2.1
* @license LGPL
**/
@@ -807,8 +807,9 @@
}
}(this));
+/* Optional elevation addon requires Googlemaps API JS */
-/*global google:true require:true module:true elevationResult*/
+/*global google:true geolib:true require:true module:true elevationResult*/
/**
* @param Array Collection of coords [{latitude: 51.510, longitude: 7.1321}, {latitude: 49.1238, longitude: "8° 30' W"}, ...]
*
@@ -878,14 +879,14 @@ geolib.getElevationServer = function(coords, cb) {
for(var i = 0; i < coords.length; i++) {
path.push(geolib.useDecimal(coords[i][latitude]) + ',' +
- geolib.useDecimal(coords[i][longitude]));
+ geolib.useDecimal(coords[i][longitude]));
}
gm.elevationFromPath(path.join('|'), path.length, function(err, results) {
geolib.elevationHandler(results.results, results.status, coords, keys, cb);
});
-};
+},
geolib.elevationHandler = function(results, status, coords, keys, cb){
var latsLngsElevs = [];
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
Oops, something went wrong.

0 comments on commit 6718a9d

Please sign in to comment.