[Mapbender-commits] r6392 - trunk/mapbender/lib

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Tue Jun 22 10:31:18 EDT 2010


Author: christoph
Date: 2010-06-22 14:31:18 +0000 (Tue, 22 Jun 2010)
New Revision: 6392

Modified:
   trunk/mapbender/lib/wizard.js
Log:


Modified: trunk/mapbender/lib/wizard.js
===================================================================
--- trunk/mapbender/lib/wizard.js	2010-06-22 14:27:54 UTC (rev 6391)
+++ trunk/mapbender/lib/wizard.js	2010-06-22 14:31:18 UTC (rev 6392)
@@ -40,10 +40,12 @@
 			if (arguments.length === 2) {
 				var $target = arguments[1];
 				var href = "#" + $target.id;
+				var me = null;
 			}
 			else {
 				var href = $(this).attr("href");
 				var $target = $(href);
+				var me = this;
 			}
 			var found = false;
 			var abort = false;
@@ -67,7 +69,7 @@
 				return;
 			}
 
-			var proceed = o.onBeforeClickLink(e, $(this));
+			var proceed = me === null ? true : o.onBeforeClickLink(e, $(me));
 			if (proceed === false) {
 				new Mapbender.Warning("Clicked link " + href + " in wizard " + wizardInstance.id + " aborted!");
 				return;
@@ -84,7 +86,7 @@
 				return;
 			}
 			if (options === "to" && arguments.length === 2) {
-				return to.apply(this, [null, arguments[1]]);
+				return to(null, arguments[1]);
 			}
 			console.log("invalid command!");
 			return;



More information about the Mapbender_commits mailing list