[Pkg-javascript-commits] [leaflet] 103/301: Added getBounds function to CRS

Jonas Smedegaard js at moszumanska.debian.org
Mon Jan 27 22:22:44 UTC 2014


This is an automated email from the git hooks/post-receive script.

js pushed a commit to branch master
in repository leaflet.

commit b78249865078be2f89afe9aeb58b8e32a6a336c0
Author: perliedman <per.liedman at kartena.se>
Date:   Mon Sep 23 09:58:42 2013 +0200

    Added getBounds function to CRS
---
 src/geo/crs/CRS.js | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/geo/crs/CRS.js b/src/geo/crs/CRS.js
index cb70d9b..f8ccbaa 100644
--- a/src/geo/crs/CRS.js
+++ b/src/geo/crs/CRS.js
@@ -23,5 +23,10 @@ L.CRS = {
 
 	scale: function (zoom) {
 		return 256 * Math.pow(2, zoom);
-	}
+	},
+
+	getBounds: function (zoom) {
+		var s = this.scale(zoom);
+		return [s, s, s, s];
+   	}
 };

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/leaflet.git



More information about the Pkg-javascript-commits mailing list