
  /**
   * Min/Max map and Branches/Products-panel
   * Site depending fitting is done by css
   */ 
  
  var homeMarker;
  var gmapTransCtrl;
  var gmapTypeCtrl;
  var baseZoom = 15;
  

	function initShopShow() {
  	//############## Map ################
	  if (!initMap({
      mapContainer: document.getElementById("gmapMap"),
      //transformControl: gmapTransCtrl,
      //typeControl: gmapTypeCtrl,
      mouseZoomable: false
    })) {
      return;
    }
    
		var homeIcon = new GIcon(G_DEFAULT_ICON);//, wgScriptPath + "/extensions/BeautyKompass/gfx/marker_home2.png");
		homeIcon.image = wgScriptPath + "/extensions/BeautyKompass/gfx/marker_home.png";
		homeIcon.shadow = wgScriptPath + "/extensions/BeautyKompass/gfx/marker_home_shaddow.png";
		homeIcon.iconSize = new GSize(26, 29);
		homeIcon.shadowSize = new GSize(35, 29);
		homeIcon.iconAnchor = new GPoint(12, 28);
		homeIcon.infoWindowAnchor = new GPoint(25, 5);
		homeIcon.infoShadowAnchor = new GPoint(25, 5);

    // Set initial location
    if (homePos != null) {
      //homePos = new GLatLng(homePos.lat, homePos.lng);
      gmap.setCenter(homePos, baseZoom);
    } else {
      gmap.setCenter(new GLatLng(51.908294, 10.422580), baseZoom);
    }
    
    var bounds = new GLatLngBounds();
    // Add marker to the map
    //if (homePos != null) {
      homeMarker = addMarker(homePos, {icon: homeIcon, draggable: false, clickable: false});
      bounds.extend(homePos);
    //}
    var z = gmap.getBoundsZoomLevel(bounds);
    var baseZoomReel = (z < baseZoom) ? z - 1 : baseZoom;
  	gmap.setCenter(homePos, baseZoomReel);
  	//############## / Map ################

  	//############## Min/Max Link ################
    var minMaxLink = new MinMaxLink(
      document.getElementById('gmapContainer'),
      document.getElementById('gmapMap'),
      200, 200,
      478, 400,
      10,
      homePos,
      baseZoomReel
      );
  	//############## / Min/Max Link ################
    
  	//############## ImageShifter ################
  	if (shopImages.length > 0) {
  		var imageShifter = new ImageShifter(
  			'bkShopShowImages',
  			document.getElementById('bkShopShowImages'),
  			shopImages,
  			{scrollType: 1, scrollSpeed: 250, holdDelay: 100, scrollStepping: 10, hoverImages: false }
  		);
  	//############## / ImageShifter ################
  	}
  	
	}

addOnloadHook(initShopShow);
//window.addEvent('domready', initShopShow);

