[Mapbender-commits] r10339 - trunk/mapbender/http/plugins

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Tue Nov 19 01:54:12 PST 2019


Author: armin11
Date: 2019-11-19 01:54:12 -0800 (Tue, 19 Nov 2019)
New Revision: 10339

Added:
   trunk/mapbender/http/plugins/mb_carouselContainer.js
Log:
thanx to karlo

Added: trunk/mapbender/http/plugins/mb_carouselContainer.js
===================================================================
--- trunk/mapbender/http/plugins/mb_carouselContainer.js	                        (rev 0)
+++ trunk/mapbender/http/plugins/mb_carouselContainer.js	2019-11-19 09:54:12 UTC (rev 10339)
@@ -0,0 +1,24 @@
+var $toolbar = $(this);
+
+var ToolbarApi = function (o) {
+	var that = this;
+	
+	var $list = $("<ul id='carouselContainer' />").appendTo($toolbar);
+	o.$target.each(function () {
+		if (this === undefined) {
+			return;
+		}
+		$list.append($(this).wrap("<li />").parent());
+	});
+};
+
+$toolbar.mapbender(new ToolbarApi(options));
+
+$(document).ready(function(){
+        $('#carouselDiv_btn').click(function(){
+		$('#carouselContainer').toggle();
+		$('#carouselContainer').click(function(event){event.stopPropagation();});
+		$('#carouselDiv_btn').toggleClass('carouselDiv_btn_Opened');
+		$('.carouselDiv_btn_name').toggle();
+	})
+});



More information about the Mapbender_commits mailing list