/**
 * scroll the header banner.
 */

var Scroller = {

    init: function()
    { 	
    	var num_img = $(".header-div img").length;
    	var width = num_img*183;
    	
    	// set width of container
    	$(".header-div").css('width',width+'px');
    	
    	setInterval(function () {  	  
    		var left = $(".header-div").position().left;
			if (left<-0.5*width) {
				$(".header-div").css("left",0);
			} else {
				$(".header-div").css("left",left-1);
			}
		}, 10);
    }
}

$(document).ready(Scroller.init);

