jQuery.fn.extend({
  scrollTo : function(speed, easing) {
    <!-- hashの取得が出来なければ、処理を中断 -->

    return this.each(function() {
      var targetOffset = $($(this)[0].hash).offset().top;
      $('html,body').animate({scrollTop: targetOffset}, speed, easing);
    });
  }
});

$(document).ready(function(){
	
	$('#photos').galleryView({
		panel_width: 570,
		panel_height: 350,
		frame_width: 100,
		frame_height: 100,
    	overlay_color: '#222',
    	overlay_text_color: 'white',
    	caption_text_color: '#333',
    	background_color: 'transparent',
   		border: 'none',
    	nav_theme: 'light',
    	easing: 'easeInOutQuad',
    	pause_on_hover: true,
		transition_interval: 5000,
		transition_speed:700,
		overlay_height:85
	});

	$(function(){
    var $targetElement = '.wordBreak';
    if($.browser.msie) {
        $($targetElement).css('word-break', 'break-all');
    } else {
        $($targetElement).each(function(){
            if(navigator.userAgent.indexOf('Firefox/2') != -1) {
                $(this).html($(this).text().split('').join('<wbr />'));
            } else {
                $(this).html($(this).text().split('').join(String.fromCharCode(8203)));
            }
        });
    }});

    $('#tweetsFeed').jTweetsAnywhere({
    username: '06tunnel',
    count: 10,
    showConnectButton: false,
    showLoginInfo: false,
	showFollowButton: false
    });
    $('#tweetstweet').jTweetsAnywhere({
    showTweetBox: {
		counter: true,
		width: 310,
		height: 50,
		label:"",
		defaultContent: 'ご質問等いつでも受け付けています。ツイッターアカウントがあれば「@06tunnel ～内容～」でここからtweetできます！'
	},
    showConnectButton: false,
    showLoginInfo: false
    });


/*
$('#pager_wrap').pajinate(
{items_per_page : 10,					nav_label_first : 'NEW',
					nav_label_last : 'OLD',
					nav_label_prev : '前の10件',
					nav_label_next : '次の10件'
		}
);

 $(".page_navigation a").attr({ href:"#wn_top" });

<script type="text/javascript" src="_common/js/jquery.pajinate.min.js"></script>
<script type="text/javascript" src="_common/js/jquery.lazyload.mini.js"></script>

$(".whatsnew_item-photo").lazyload({
      placeholder : { src : "loading.gif", width : 200, height : 125 },
      effect : "fadeIn",
	  threshold : 50
});


*/
  $('a[href*=#]').click(function() {
    $(this).scrollTo(1300);
    return false;
  });
});