/**
 * @name main.js
 * @fileOverview
 * @version 1.0
 * @description
 * <p>(c) FOURDIGIT Inc. Licensed <a href="http://ja.wikipedia.org/wiki/GNU_General_Public_License">GNU General Public License</a>.</p>
 */
//他ライブラリと共存する場合、下の一行削除($無効化)
//jQuery.noConflict();
(function($){
	var config = function () {
	//bodyのクラスにブラウザ情報を追加
		$.addClassUA();
	//easyOverのターゲット設定
		$("img.ahover, .ahoverArea img").easyOver();
	//IE5,6にてPNG有効化 (pngfixの読み込みが必要)
		//$("img[src$=png],p.png").enablePNG();
	//Flash
		//$("object, embed").enableFlash();
	//ポップアップリンクに置換
		$(".commonPop").easyPop();
	//他ドメインリンク時にpageTracker有効化
		//$("a,area").blankLogToGoogle();
	//アンカーリンクをスムージング
		$("a[href^=#]").smoothScroll(4);
	//対象の要素をスクロールに追従するようにする
		//$("#fixBox").fixPosition("stopperID","normal");
	}

	//onload 追記
	$(function() {
		config();
		$('#conteWorks').each(function(){
			$('.worksList li .text').autoHeight({column:4});
			$('.worksList li .img a[rel], .worksList li .text a[rel]').overlay({
				close: '.btnClose',
				top: 50,
				mask: {
					color: '#000000'
				},
				closeOnClick: true,
				fixed: false
			});
		});
		$('.worksImg').each(function(){
			var img = $(this).find('.mainImg img');
			$(this).find('.thumbnail li a').click(function(){
				var img_src = $(this).attr('href');
				img.hide();
				img.attr('src', img_src);
				img.fadeIn();
				return false;
			});
		});
		$('#conteProject').each(function(){
			$('.projectSub li').autoHeight({column:2});
		});
	});

})(jQuery);
