[Mapbender-commits] r6288 - trunk/mapbender/lib
svn_mapbender at osgeo.org
svn_mapbender at osgeo.org
Thu Jun 17 07:31:13 EDT 2010
Author: christoph
Date: 2010-06-17 11:31:13 +0000 (Thu, 17 Jun 2010)
New Revision: 6288
Modified:
trunk/mapbender/lib/basic.js
Log:
Modified: trunk/mapbender/lib/basic.js
===================================================================
--- trunk/mapbender/lib/basic.js 2010-06-17 11:15:22 UTC (rev 6287)
+++ trunk/mapbender/lib/basic.js 2010-06-17 11:31:13 UTC (rev 6288)
@@ -381,7 +381,9 @@
return text;
};
-
+/*
+ * Link between various interfaces, imagine a wizard
+ */
$.fn.wizard = function () {
return this.each(function () {
var $module = $(this);
@@ -392,25 +394,28 @@
var $target = $(href);
var target = $target.mapbender();
-
var showTarget = function () {
$target.show();
};
if (typeof target === "object" && typeof target.show === "function") {
showTarget = function () {
+ // calls the show function of the module, not jQuery's show
target.show();
};
}
- var clickHandler = function () {
+ var clickHandler = function (e) {
$module.hide();
showTarget();
+ e.preventDefault();
};
if (typeof module === "object" && typeof module.hide === "function") {
- clickHandler = function () {
+ clickHandler = function (e) {
+ // calls the hide function of the module, not jQuery's hide
module.hide(showTarget);
+ e.preventDefault();
};
}
More information about the Mapbender_commits
mailing list