var Context = {
WEBEDIT_MODULE_ACCESSOR:'wemod',
COMPONENT_ACCESSOR:'cmp',
COMPONENT_ID_ACCESSOR:'cmpref',
COMPONENT_LANG_ACCESSOR:'lang',
GENERIC_MODULE_NAME:'generic',
PARENT_ID_ACCESSOR:'parentref',
VALUE_ACCESSOR:'value',
LABEL_ACCESSOR:'label',
TREE_FILTER:'treeFilter',
LANG_ACCESSOR:'lang',
FULL_TREE_CONTENT_ACCESSOR:'fullTreeContent',
LINKED_COMPONENT_ACCESSOR:'lnkcmp',
MODULE_ACCESSOR:'module',
ACTION_ACCESSOR:'action',
CALLER_MODULE:'website',
CALLER_ACTION:'Display',
W_HOST_PREFIX:'http://',
W_HOST:'www.sbr.fr',
UIHOST_PREFIX:'http://',
UIHOST:'www.sbr.fr',
UIBASEURL:'http://www.sbr.fr',
W_SIGNED_FLAG:'signedView=1',
inDragSession:false,
W_LANG:'fr',
FORWARD_TO_MODULE:'fmodule',
FORWARD_TO_ACTION:'faction'};

var K = {
WEBEDIT_MODULE_ACCESSOR:'wemod',
COMPONENT_ACCESSOR:'cmp',
COMPONENT_ID_ACCESSOR:'cmpref',
COMPONENT_LANG_ACCESSOR:'lang',
GENERIC_MODULE_NAME:'generic',
PARENT_ID_ACCESSOR:'parentref',
VALUE_ACCESSOR:'value',
LABEL_ACCESSOR:'label',
TREE_FILTER:'treeFilter',
LANG_ACCESSOR:'lang',
FULL_TREE_CONTENT_ACCESSOR:'fullTreeContent',
LINKED_COMPONENT_ACCESSOR:'lnkcmp'};
if (visualCount > 4)
{
	// Set default values for the tag used for next and previous buttons and their content.
	if (typeof(buttonType) == undefined || buttonType == undefined)
	{
		var buttonType = 'button';
	}
	
	if (typeof(buttonPrevContent) == undefined || buttonPrevContent == undefined)
	{
		var buttonPrevContent = '&lt;';
	}
	else if (buttonPrevContent == 'none')
	{
		buttonPrevContent = '';
	}
	
	if (typeof(buttonLastContent) == undefined || buttonLastContent == undefined)
	{
		var buttonLastContent = '&gt;';
	}
	else if (buttonLastContent == 'none')
	{
		buttonLastContent = '';
	}
	
	$(document).ready(function() {
		// Add the buttons.
		$('.product-recommand').before('<li><'+buttonType+' class="prev">'+buttonPrevContent+'</'+buttonType+'></li><li><'+buttonType+' class="next" style="margin-right: 5px;">'+buttonLastContent+'</'+buttonType+'></li>');
	
		// Intitialize the carousel.
		$(".product-pictures .jcarousellite").jCarouselLite({
		    btnNext: ".product-pictures .next",
		    btnPrev: ".product-pictures .prev",
		    speed: 200,
		    vertical: true,
		    circular: false,
		    mouseWheel: true,
		    visible: 4
		});
	});
}

$(document).ready(function() {
	$('.zoomable').click(function() { 
		$(this).find('img.image').each(function() { 
			zoom.initialize(this, true); 
		}); 
		return false; 
	});
});