$(function() {
	// 連携キット、local時はexit
	if ($.LiVE.bdkit && location.protocol=="file:") return;
	
	var $navi = $.LiVE.Elements.WIDGETS.navi.find(".default_autopilot");
	$navi.each(function() {
		var $this = $(this),
			$button = $this.find("img"),
			_url = "?mode=presentation",
			_id = "LiVE" + Math.floor(Math.random()*10000);
		
		if (location.search.match(/mode=presentation/)) {
			$this.remove();
			return;
		}
		$this.find("a").click(function() {
			if (typeof(soundManager) != 'undefined') {
				if (soundManager) $.LiVE.panelsound.mute(true);
			}
			
			var _screen = window.open(_url, _id, "toolbar=0,menubar=0,location=0,scrollbars=1,left=0,top=0,width="+screen.availWidth+",height="+screen.availHeight+",fullscreen=1");
			_screen.focus();
		});
	});
});