/*
 * $Id: historyPanel.js 4337 2010-04-26 10:21:04Z ba\toshk $
 */


if (!window.fujifilm){ var fujifilm = {}; }

(function(ff){
	var $ = jQuery;
	ff.HistoryPanel = HistoryPanel;
	
	function HistoryPanel ( jQueryObj, id ) {
		this._body = jQueryObj;
		this._id = id;
		this._tweenTime = 300;
	}
	HistoryPanel.prototype = new ff.CarouselPanel();
	HistoryPanel.prototype.assignObjects = function () {
		this._viewPort = this._body.find('div.viewPort').eq(0);
		this._unitGroup = this._viewPort.find('div.itemGroup').eq(0);
		this._units = this._unitGroup.find('div.item');

		this._switchPanelParent = this._body.find('div.header').eq(0);
		this._switchPanelAddMode = 'to';
	}
	HistoryPanel.prototype.adjustParams = function () {
		var viewPortParentWidth = this._viewPort.parent().width();
		this._scrollWidth = viewPortParentWidth + 30;
		this._dispUnitsNum = 3;
	}
	HistoryPanel.prototype.ajust = function () {
		this._unitGroup.css('marginRight', 0);
	}
})(fujifilm);

jQuery(function($){
	var $hpanel = $('div.ps01-footer02 > div.historyPanelA01');
	for (var i = 0; i < $hpanel.length; i++) {
		var vp = new fujifilm.HistoryPanel( $hpanel.eq(i), 'A01' );
		vp.setUp();
	}
});
