if(typeof eyevio=="undefined"){eyevio={}}Event.observe(window,"load",function(){if(!location.host.startsWith("admin")){setTimeout(httpsToHttpAll,100)}preload(["/img/btn_add_hover.gif","/img/btn_add_on.gif","/img/btn_back_hover.gif","/img/btn_send_hover.gif","/img/btn_signup_hover.gif","/img/btn_next_on.gif","/img/btn_ok_hover.gif","/img/btn_ok_en_hover.gif","/img/btn_cancel_hover.gif","/img/btn_regist_hover.gif","/img/icon_delete_hover.gif","/img/btn_ok2_hover.gif"]);eyevio.tutorial.onload()});function httpsToHttpAll(){if(location.href.indexOf("https")==0){var A=document.getElementsByTagName("a");for(var B=0;B<A.length;B++){httpsToHttp(A[B])}}}function httpsToHttp(A){var B=A.href;if(B.indexOf("https")==0&&!Element.hasClassName(A,"ssl")){B="http://"+location.host+B.replace(/https?:\/\/[^\/]+/,"");A.href=B}}function changeLocation(A){if(location.href.indexOf("https")==0){location.href="http://"+location.host+A.replace(/https?:\/\/[^\/]+/,"")}else{location.href=A}}function updateContent(E,A,F){var D="/ajax/get.do?id="+E;var B=(A!=undefined)?A:E;var C=undefined;if(F==undefined){C={asynchronous:true,method:"get",evalScripts:true,onFailure:reportError}}else{if(typeof (F)=="function"){C={asynchronous:true,method:"get",evalScripts:true,onFailure:reportError,onComplete:F}}else{if(typeof (F)=="object"){C=F}}}new Ajax.Updater(B,D,C)}eyevio.iframereq={callbacks:{},register:function(A,B){this.callbacks[A]=B},_callback:function(A){var B=this.callbacks[A];if(B){B.apply(null,arguments)}}};function addBookmark(H,F,B,D){setTimeout(function(){pageTracker._trackPageview("/"+type+"/video/add_to_channel/open")},0);var C="/ajax/getBookmarkChannelInfo.do?movieId="+H;var E=new Ajax.Request(C,{asynchronous:false,method:"get",onSuccess:A,onFailure:G});function G(){element.value="ERROR";return }function A(N){var K="";if(N.responseText==""||N.responseText==null||N.responseText==undefined){skdialog.alert("追加できるチャンネルがありません。",null,{title:"チャンネルに追加"});return }else{if(window.EmpAdapter){EmpAdapter.pauseVideo()}var O=responseTextFilter(N.responseText);var J=O.split("\n");for(var L=0;L<J.length;L++){var I=J[L].split("\t");if(I[2]=="true"){K+='<tr>  <td class="col-itemname-b" style="width:400px"><div class="ellipsis" style="width:350px">'+I[1].toXml()+'</div></td>  <td class="col-btn">	<ul class="item-action" style="float:none";>	  <li class="done"><a/></li>	</ul></td></tr>'}else{K+='<tr>  <td class="col-itemname-b" style="width:400px"><div class="ellipsis" style="width:350px;">'+I[1].toXml()+'</div></td>  <td class="col-btn">	<ul class="item-action" style="float:none";>	  <li class="add"><a href="javascript:void(0)"		onclick="ajaxPost(\'/ajax/addBookmark.do\',				\'actionSID='+getCookie(sidName)+"&id="+H+"&type="+type+"&bid="+toXml(I[0])+"',				function() { eyevio.tutorial.notifyAction(eyevio.tutorial.ACTION_ADD_MOVIE_TO_BOOKMARK); }			);			this.parentNode.className = 'done';			this.className = null;			this.removeAttribute('href');			this.onmouseover = null; this.onmouseout = null; this.onclick = null;\"		onmouseover=\"enterDiv(this)\"		onmouseout=\"leaveDiv(this)\"></a></li>	</ul></td></tr>"}}var M='<div id="ActionPanelFloater"><div id="ActionPanelFloaterWindow"><div class="inner" style="padding-bottom: 22px">  <div class="content" id="addchlist">	<p class="actionpanel-read"><strong class="itemname"><p class="ellipsis" id="addchtitle" style="max-width:300px; float:left;">『'+F.toXml()+'</p>』</strong>を追加するチャンネルを選択してください。</p>	<div id="pane-addchlist" class="pane-addchlist">	  <table class="input-form-addchlist" id="addchtable">		<colgroup class="col-itemname-b" />		<colgroup class="col-btn" />		<thead>		<tr>		  <th class="col-itemname-b">項目名</th>		  <th class="col-btn">ボタン</th>		</tr>		</thead>		<tbody>'+K+'</tbody>	  </table>	</div>  </div>  <ul class="list-action">	<li class="quit"><a id="skdialog_close_button" href="javascript:void(0)" onclick="skdialog.close()">終了</a></li>  </ul></div></div></div>';skdialog.show({title:"チャンネルに追加",content:M,width:560,startElement:D,onOpen:function(){ellipsisAll("addchlist");if(getIEVersion()==6){$("addchtitle").style.width=($("addchtitle").clientWidth>300)?"300px":"auto"}},onClose:function(){if(window.EmpAdapter){EmpAdapter.playVideo()}}})}}reloadBanner();return false}function addScrapBookmark(D,C,A,B){skdialog.confirm('<strong class="itemname"><p id="addScrapbookTitle" class="ellipsis" style="max-width:350px; float:left;">『'+C.toXml()+"</p>』</strong>を スクラップブックに追加",function(){setTimeout(function(){pageTracker._trackPageview("/"+type+"/scrapbook/add/"+D)},0);ajaxPost("/ajax/addBookmark.do","actionSID="+getCookie(sidName)+"&id="+D+"&type="+type,function(){eyevio.tutorial.notifyAction(eyevio.tutorial.ACTION_ADD_CHANNEL_TO_SCRAPBOOK)})},{title:"スクラップブックに追加",onOpen:function(){ellipsis("addScrapbookTitle");if(getIEVersion()==6){var E=$("addScrapbookTitle");E.style.width=(E.clientWidth>350)?"350px":"auto"}},startElement:B});reloadBanner();return false}function registerMyChannel(A,E,D,B){var C='<strong class="itemname"><p id="registerMyChannelTitle" class="ellipsis" style="max-width:400px; float:left">『'+E.toXml()+"</p>』</strong>をマイチャンネルに追加します。<br />マイチャンネルに追加すると、このチャンネルにビデオを投稿出来るようになります。";if(D){C+='<br /><br />オーナーからのメッセージ：<pre style="width: 420px; height: 72px; overflow: auto">'+D.toXml()+"</pre>"}skdialog.confirm(C,function(){setTimeout(function(){pageTracker._trackPageview("/"+type+"/shared_channel/subscribe")},0);ajaxPost("/ajax/registerMyChannel.do","actionSID="+getCookie(sidName)+"&bid="+A,function(F){skdialog.alert(responseTextFilter(F.responseText),function(){location.reload()})})},{title:"このチャンネルに参加",onOpen:function(){ellipsis("registerMyChannelTitle");if(getIEVersion()==6){var F=$("registerMyChannelTitle");F.style.width=(F.clientWidth>350)?"420px":"auto"}},startElement:B})}function openKeywordChannelForm(A,D,C){var B='<div id="ActionPanelFloater"><div id="ActionPanelFloaterWindow">	<div class="inner editor">	  <div class="content">		<form onsubmit="return registerKeywordChannel(\''+D+'\');">		<p class="actionpanel-read">チャンネルを新規登録します。チャンネル名を入力してください。</p>		<table class="input-form">		  <colgroup class="col-itemname" />		  <colgroup class="col-input" />		  <colgroup class="col-note" />		  <thead>			<tr>			  <th class="col-itemname">項目名</th>			  <th class="col-input">入力欄</th>			  <th class="col-note">備考</th>			</tr>		  </thead>		  <tbody>			<tr>			  <td class="col-itemname">チャンネル名</td>			  <td class="col-input"><input id="add_bookmark_form_name" class="formtext" type="text" title="名前を入力" value="検索 - '+A.toXml()+'"/></td>			  <td class="col-note"></td>			</tr>		  </tbody>		</table>		<ul class="list-action">		<li class="successMessage"><!--編集内容は保存されました。 --></label>		<li class="finish" style="padding: 5px"><input type="image" id="add-channel-button" class="btn-add" alt="追加" title="追加" src="/img/btn_add_default.gif" onmouseover="img_change(this, \u0027/img/btn_add_hover.gif\u0027)" onmouseout="img_restore(this)" /></li>		<li class="quit"><a href="javascript:void(0)" onclick="return skdialog.close()">終了</a></li>		</ul>		</form>	  </div>	</div>	</div></div>';skdialog.show({title:"チャンネルの追加",content:B,focusId:"add_bookmark_form_name",startElement:C});reloadBanner();return false}function registerKeywordChannel(B){var A=$("add_bookmark_form_name");if(!checkInputWord(A.value,function(){skdialog.alert("チャンネル名を入力してください。",null,{title:"チャンネルの追加"})})){}else{setTimeout(function(){pageTracker._trackPageview("/"+type+"/video_search/register")},0);ajaxPost("/ajax/registerKeywordChannel.do","actionSID="+getCookie(sidName)+"&"+B+"&name="+encodeURIComponent(A.value),function(){skdialog.close();eyevio.tutorial.notifyAction(eyevio.tutorial.ACTION_ADD_SEARCH_CHANNEL)})}return false}function rateMovie(G,E,F,B,A){var D=$("action-point");if(!D||Element.hasClassName(D,"disable")){return }var C="/ajax/ratingMovie.do";var H="imageOwnerId="+E+"&movieId="+B+"&value="+G;setTimeout(function(){pageTracker._trackPageview("/"+type+"/video/evaluate")},0);ajaxPost(C,H,function(){var I=Number($("hidden_point").value);I++;I=""+I;var J="";var K=0;for(var L=I.length;L>-1;L--){J=I.charAt(L)+J;if(K%3==0&&L<I.length&&L!=0){J=","+J}K++}Element.addClassName(D,"disable");Element.update("pointValue",J);$("rateMovieLink").style.display="none"})}function deleteBlogLink(A,B){skdialog.confirm("ブログの URL を削除しますか？",function(){setTimeout(function(){pageTracker._trackPageview("/"+type+"/blog_url/delete")},0);ajaxPost("/ajax/deleteBlogLink.do","actionSID="+getCookie(sidName)+"&movieId="+A);if($("blogLink")){Element.hide("blogLink")}},{title:"ブログのURL削除",startElement:B});return false}eyevio.addressSelector={toggle:function(C,D,A,B){if(Element.hasClassName(A,"opened")){Element.removeClassName(A,"opened");Element.hide(B)}else{this.textElem=D;new Ajax.Request("/ajax/getAddressBooks.do",{asynchronous:true,method:"get",onFailure:reportError,onComplete:function(F){var H="<ul>";var E=F.responseText.split("\n");for(var G=0;G<E.length;G++){var I=E[G].split("\t");H+='<li onclick="eyevio.addressSelector.add(\u0027'+toXml(toJSStr(I[1]))+'\u0027);" style="cursor: pointer; white-space: nowrap; color: #FFF;" onmouseover="this.style.backgroundColor=\u0027#fff097\u0027; this.style.color=\u0027#F60\u0027;" onmouseout="this.style.backgroundColor=\u0027transparent\u0027; this.style.color=\u0027#FFF\u0027;" title="'+toXml(I[1])+'">'+toXml(I[0]?I[0]:I[1])+"</li>"}H+="</ul>";B.innerHTML=H;Element.show(B);Element.addClassName(A,"opened")}})}},add:function(A){if(this.textElem.nodeName=="TEXTAREA"){this.textElem.value+=A+"\n"}else{this.textElem.value=A}}};eyevio.recentTagSelector={toggle:function(C,D,A,B){if(Element.hasClassName(A,"opened")){Element.removeClassName(A,"opened");Element.hide(B)}else{this.textElem=D;new Ajax.Request("/ajax/getRecentTags.do",{asynchronous:true,method:"get",onFailure:reportError,onComplete:function(F){var H="<ul>";var E=F.responseText.split(" ");for(var G=0;G<E.length;G++){if(E[G]){H+='<li onclick="eyevio.recentTagSelector.add(\u0027'+toXml(toJSStr(E[G]))+'\u0027);" style="cursor: pointer; white-space: nowrap; color: #FFF;" onmouseover="this.style.backgroundColor=\u0027#fff097\u0027; this.style.color=\u0027#F60\u0027;" onmouseout="this.style.backgroundColor=\u0027transparent\u0027; this.style.color=\u0027#FFF\u0027;" title="'+toXml(E[G])+'">'+toXml(E[G])+"</li>"}}H+="</ul>";B.innerHTML=H;Element.show(B);Element.addClassName(A,"opened")}})}},add:function(A){if(this.textElem.value){this.textElem.value+=" "+A}else{this.textElem.value=A}}};function reloadBanner(){if(navigator.userAgent.indexOf("Gecko")==-1&&navigator.userAgent.indexOf("MSIE")==-1){var D=$("TopBanner");if(D){Element.update(D,getTopBannerHtml())}}else{var A=frames.topBannerIframe;if(A){var G="IMPASEG";var F=document.cookie;var B=F.indexOf(G+"=");var C=(B!=-1)?F.substring(B+G.length+1,(F.indexOf("; ",B)!=-1)?F.indexOf("; ",B):F.length):null;C=(C)?unescape(C):null;impAserver="http://as.dc.impact-ad.jp";impAtag="/SITE=MV.EYEVIO.DAC/AREA=PAGE/AAMSZ=468X60";impAtarget=(C)?impAtag+"/"+C:impAtag;impArnd=Math.round(Math.random()*100000000);if(!E){var E=Math.round(Math.random()*100000000)}A.location.replace(impAserver+"/hserver/acc_random="+impArnd+impAtarget)}}}function getTopBannerHtml(){var F="IMPASEG";var E=document.cookie;var B=E.indexOf(F+"=");var C=(B!=-1)?E.substring(B+F.length+1,(E.indexOf("; ",B)!=-1)?E.indexOf("; ",B):E.length):null;C=(C)?unescape(C):null;impAserver="http://as.dc.impact-ad.jp";impAtag="/SITE=MV.EYEVIO.DAC/AREA=PAGE/AAMSZ=468X60";impAtarget=(C)?impAtag+"/"+C:impAtag;impArnd=Math.round(Math.random()*100000000);if(!D){var D=Math.round(Math.random()*100000000)}var A='<iframe id="topBannerIframe" name="topBannerIframe" src="'+impAserver+"/hserver/acc_random="+impArnd+impAtarget+'" noresize scrolling="no" hspace="0" vspace="0" frameborder="0" marginheight="0" marginwidth="0" width="468" height="60" allowTransparency="true">';if(navigator.userAgent.indexOf("Gecko")==-1&&navigator.userAgent.indexOf("MSIE")==-1){A+='<script src="'+impAserver+"/jnserver/acc_random="+impArnd+impAtarget+"/pageid="+D+'"><\/script>'}A+="</iframe>";return A}eyevio.embed={wide:false,size:1,mode:1,movieId:null,channelId:null,open:function(A,E,B,C){setTimeout(function(){pageTracker._trackPageview("/"+type+"/html_code/open")},0);if(window.EmpAdapter){EmpAdapter.pauseVideo()}this.wide=B;this.movieId=A;this.channelId=E;var D='<div id="ActionPanelFloater"><div id="ActionPanelFloaterWindow"><div class="inner"><div class="content">	<p class="actionpanel-read">ブログなどへこのビデオのプレイヤーを貼り付ける場合は下記のコードを使用ください。</p>	<table class="input-form"><tbody>		<tr>			<td nowrap>プレイヤーのサイズ選択</td>			<td><input type="radio" name="embedSize" id="embedSizeId1" onclick="eyevio.embed.writeEmbedVideoTextArea(1);" style="vertical-align:middle" checked="checked"><label for="embedSizeId1"> 大（標準） </label>			<input type="radio" name="embedSize" id="embedSizeId2" onclick="eyevio.embed.writeEmbedVideoTextArea(2);" style="vertical-align:middle"><label for="embedSizeId2"> 中 </label>			<input type="radio" name="embedSize" id="embedSizeId3" onclick="eyevio.embed.writeEmbedVideoTextArea(3);" style="vertical-align:middle"><label for="embedSizeId3"> 小 </label></td>		</tr>		<tr>			<td class="col-itemname">タグ選択</td>			<td><input type="radio" name="embedTag" id="embedTagId1" onclick="eyevio.embed.writeEmbedVideoTextArea(null, 1);" style="vertical-align:middle" checked="checked"><label for="embedTagId1"> 標準(iframe) </label>			<input type="radio" name="embedTag" id="embedTagId2" onclick="eyevio.embed.writeEmbedVideoTextArea(null, 2);" style="vertical-align:middle"><label for="embedTagId2"> オプション(object) </label><p style="margin-top:3px;font-size:10px;_font-size:9px;">※ 「標準」を使用してビデオを貼り付けられない場合、「オプション」をお試しください。</p></td>		</tr>	</tbody></table>	<p style="font-size:12px">このビデオの貼付けコード</p>	<textarea class="embedText" id="embedVideoTextarea" onfocus="this.select()"></textarea>'+(E?'<p style="margin-top:5px;font-size:12px;">このチャンネルの貼付けコード（チャンネル内のビデオ全てを貼付ける場合）</p><textarea class="embedText" id="embedChannelTextarea" onfocus="this.select()"></textarea>':"")+'	<ul class="list-action"><li class="quit"><a href="javascript:void(0)" onclick="skdialog.close()">終了</a></li></ul></div></div></div></div>';skdialog.show({title:"貼付けコード",content:D,width:560,height:560,focusId:"embedVideoTextarea",startElement:C,onClose:function(){this.isShowing=false;if(window.EmpAdapter){EmpAdapter.playVideo()}}.bind(this),onOpen:function(){this.isShowing=true;this.writeEmbedVideoTextArea();reloadBanner()}.bind(this)})},writeEmbedVideoTextArea:function(B,D){if(B){this.size=B}if(D){this.mode=D}var A=330;var C=this.wide?521:400;if(this.size==2){A=248;C=this.wide?391:300}else{if(this.size==3){A=165;C=this.wide?261:200}}if(this.mode==1){$("embedVideoTextarea").value='<iframe src="http://'+location.host+"/embed.do?movieId="+this.movieId+"&amp;width="+C+"&amp;height="+A+'" style="margin: 0px; width: '+C+"px; height: "+A+'px;" frameborder="0" scrolling="no"><a href="http://'+location.host+"/movie/"+this.movieId+'"><img src="http://'+location.host+"/file/"+this.movieId+'/w1" /></a></iframe>'}else{$("embedVideoTextarea").value=responseTextFilter(ajaxGet("/ajax/embedScript.do?plain=true&movieId="+this.movieId+"&width="+C+"&height="+A))}if($("embedChannelTextarea")){if(this.mode==1){$("embedChannelTextarea").value='<iframe src="http://'+location.host+"/embed.do?movieId="+this.movieId+"&amp;channelId="+this.channelId+'" style="margin: 0px; width: 400px; height: 386px;" frameborder="0" scrolling="no"><a href="http://'+location.host+"/movie/"+this.movieId+'"><img src="http://'+location.host+"/file/"+this.movieId+'/w1" /></a></iframe>'}else{$("embedChannelTextarea").value=responseTextFilter(ajaxGet("/ajax/embedScript.do?plain=true&movieId="+this.movieId+"&channelId="+this.channelId+"&width="+C+"&height="+A))}}},a:0};eyevio.share={open:function(B,A){setTimeout(function(){pageTracker._trackPageview("/"+type+"/share_mail/open")},0);eyevio.movieSelector.open({title:"メールでシェア",channelId:B,onSelect:this.onSelect,onClose:function(){this.isShowing=false}.bind(this),multiple:true,startElement:A});this.isShowing=true;reloadBanner()},onSelect:function(A,B){setTimeout(function(){pageTracker._trackPageview("/"+type+"/share_mail/next")},0);skdialog.changeContent({contentURL:"/ajax/dialog/shareform.do",focusId:"sendMailUploadAfterFormToAddress"});$("psForm").movies.value=A;if(!B&&A.length==1){Element.remove("private-share")}else{if(!B){Element.remove("share-password-area");$("private-read").innerHTML="閲覧期限を設定してください。"}}},openform:function(A,B){setTimeout(function(){pageTracker._trackPageview("/"+type+"/share_mail/open")},0);if(window.EmpAdapter){EmpAdapter.pauseVideo()}skdialog.show({title:"メールでシェア",contentURL:"/ajax/dialog/shareform.do?movieId="+A,onClose:function(){this.isShowing=false;if(window.EmpAdapter){EmpAdapter.playVideo()}}.bind(this),width:600,focusId:"sendMailUploadAfterFormToAddress",startElement:B});eyevio.tutorial.notifyAction(eyevio.tutorial.ACTION_OPEN_SHARE_FORM);this.isShowing=true;reloadBanner()},send:function(A){if($("share-requireAuth")){if($("share-requireAuth").checked){if(trim(A.password.value).length==0){$("sendMailError_password").innerHTML="パスワードを入力してください。";return false}if(!A.password.value.match(/[!-~]+/)){$("sendMailError_password").innerHTML="パスワードに使用できるのは半角英数字と一部の記号のみです。";return false}}$("sendMailError_password").innerHTML=""}setTimeout(function(){pageTracker._trackPageview("/"+type+"/share_mail/send")},0);return ajaxPostForm(A)},formatDate:function(A){return A.getFullYear()+"/"+this.padZero(A.getMonth()+1)+"/"+this.padZero(A.getDate())+" "+this.padZero(A.getHours())+":"+this.padZero(A.getMinutes())},padZero:function(A){if(A>9){return A}return"0"+A},generatePassword:function(){var B="";for(var A=0;A<8;A++){B+="abcdefghijklmnopqrstuvwxyz0123456789".charAt(Math.random()*36)}return B},back:function(){eyevio.movieSelector.restore()},a:0};eyevio.jasrac={openSearch:function(){setTimeout(function(){pageTracker._trackPageview("/"+type+"/video/search_music/open")},0);skdialog.show({title:"楽曲の検索・追加",contentURL:"/ajax/dialog/jasrac/search.do"+(this.params?"?"+this.params:""),width:720})},search:function(C,A){if(A){setTimeout(function(){pageTracker._trackPageview("/"+type+"/video/search_music/search_by_initial")},0)}else{if(!C){setTimeout(function(){pageTracker._trackPageview("/"+type+"/video/search_music/search")},0)}}var B=$("jasracForm");if(typeof C!="undefined"){B.offset.value=C}if(A){B.title.value="";B.artist.value=A}skdialog.changeContent({contentURL:"/ajax/dialog/jasrac/search.do?"+Form.serialize(B)})},queryIVT:function(A){skdialog.confirm('<p class="actionpanel-read">楽曲の使用範囲(ご活用形態)についてお尋ねします。</p>			<table><tbody>			<tr><td>1. 楽曲を演奏していますか？</td><td style="margin-left: 8px;"><input id="ivt_1_y" name="ivt_1" type="radio" /><label for="ivt_1_y"> はい</label></td><td style="margin-left: 8px;"><input id="ivt_1_n" name="ivt_1" type="radio" /><label for="ivt_1_n"> いいえ</label></td></tr>			<tr><td>2. 楽曲を歌っていますか？</td><td style="margin-left: 8px;"><input id="ivt_2_y" name="ivt_2" type="radio" /><label for="ivt_2_y"> はい</label></td><td style="margin-left: 8px;"><input id="ivt_2_n" name="ivt_2" type="radio" /><label for="ivt_2_n"> いいえ</label></td></tr>			<tr><td>3. 歌詞をビデオに表示していますか？</td><td style="margin-left: 8px;"><input id="ivt_3_y" name="ivt_3" type="radio" /><label for="ivt_3_y"> はい</label></td><td style="margin-left: 8px;"><input id="ivt_3_n" name="ivt_3" type="radio" /><label for="ivt_3_n"> いいえ</label></td></tr>			</tbody></table>',function(){var B=$("ivt_2_y").checked?"v":null;if(!B){B=$("ivt_1_y").checked?$("ivt_3_y").checked?"v":"i":$("ivt_3_y").checked?"t":null}if(B){A(B)}else{setTimeout(function(){skdialog.alert("歌詞/曲の利用がない場合は jasrac への申請の必要はありません。",null,{title:""})},0)}},{title:"楽曲の使用範囲のご確認",width:550})},add:function(G,E,A,C,D){this.params=D;var B=createElement("tr","jasracData_"+G);$("jasracData_tbody").appendChild(B);Element.show("jasracData_table");var F;B.appendChild(createElement("td",null,"col-title",toXml(E)));B.appendChild(createElement("td",null,"col-artist",toXml(A)));B.appendChild(createElement("td",null,"col-ivt",'<select id="jasracData_ivt_'+G+'"><option value="i">曲のみを利用</option><option value="v"'+(C=="v"?' selected="selected"':"")+'>詩/曲ともに利用</option><option value="t"'+(C=="t"?' selected="selected"':"")+">詩のみを利用</option></select>"));B.appendChild(createElement("td",null,"nowrap center",'<a onclick="eyevio.jasrac.remove(this);" href="javascript:void(0)" class="button-sub"><img src="/img/icon_delete_default.gif" onmouseover="img_change(this, \u0027/img/icon_delete_hover.gif\u0027)" onmouseout="img_restore(this)" alt="Delete" title="削除" /></a>'));if($("downloadAllowedId")){$("downloadAllowedId").checked=false}eyevio.dialogModifyChecker.modified()},remove:function(C){var B=C.nodeName.toLowerCase()=="tr"?C:parentElement(C,"tr");var A=B.parentNode;A.removeChild(B);if(!A.firstChild){Element.hide("jasracData_table")}eyevio.dialogModifyChecker.modified()},onLoad:function(B){if(!B){return }for(var A=0;A<B.length;A++){if(B[A]){eyevio.jasrac.add(B[A].id,B[A].title,B[A].artist,B[A].ivt)}}},onSubmit:function(B){try{B.jasracIds.value="";var C=firstChildElement($("jasracData_tbody"),"tr");while(C){if(C.id){var D=C.id.substr(C.id.indexOf("_")+1);var A=$("jasracData_ivt_"+D).value;B.jasracIds.value+=D+":"+A+" "}C=nextElement(C,"tr")}return true}catch(C){alert(C)}return false},a:0};eyevio.blog={open:function(B,A){setTimeout(function(){pageTracker._trackPageview("/"+type+"/blog/open")},0);eyevio.movieSelector.open({title:"ブログへ投稿",channelId:B,onSelect:this.onSelect,onClose:function(){this.isShowing=false}.bind(this),startElement:A});this.isShowing=true;reloadBanner();eyevio.tutorial.notifyAction(eyevio.tutorial.ACTION_PUSH_BLOG_BUTTON)},onSelect:function(A){setTimeout(function(){pageTracker._trackPageview("/"+type+"/blog/next")},0);skdialog.changeContent({contentURL:"/ajax/dialog/blogform.do?movieId="+A,focusId:"blog-title"});eyevio.tutorial.notifyAction(eyevio.tutorial.ACTION_SELECT_MOVIE)},openform:function(A,C,B){setTimeout(function(){pageTracker._trackPageview("/"+type+"/blog/open")},0);if(window.EmpAdapter){EmpAdapter.pauseVideo()}skdialog.show({title:"ブログに投稿",contentURL:"/ajax/dialog/blogform.do?movieId="+A+"&channelId="+C,onClose:function(){this.isShowing=false;if(window.EmpAdapter){EmpAdapter.playVideo()}}.bind(this),focusId:"blog-title",width:560,startElement:B});this.isShowing=true;reloadBanner()},send:function(A){setTimeout(function(){pageTracker._trackPageview("/"+type+"/blog/send")},0);$("blog-post-button").disabled=true;$("postBlogError_message").innerHTML="送信中...";return ajaxPostForm(A,function(){$("blog-post-button").disabled=false})},openSetting:function(){Element.hide($("postBlogFormBlock"));Element.show($("postBlogSettingBlock"));if($("blog-selector")){$("blog-selector").focus()}eyevio.tutorial.notifyAction(eyevio.tutorial.ACTION_OPEN_SETTING_BLOG)},a:0};eyevio.movieSelector={selectedMovies:new Array(),open:function(A){this.selectedMovies.clear();this.multiple=A.multiple;this.clientOnSelect=A.onSelect;this.channelId=A.channelId;this.sortable=A.sortable;skdialog.show({title:A.title,contentURL:"/ajax/dialog/movieSelector.do?channelId="+A.channelId+(A.multiple?"&multiple=true":"")+(A.sortable?"&sortable=true":""),onClose:function(){this.isShowing=false;if(A.onClose){A.onClose()}}.bind(this),startElement:A.startElement,width:A.multiple?600:560});this.isShowing=true},restore:function(){skdialog.changeContent({contentURL:"/ajax/dialog/movieSelector.do?channelId="+this.channelId+(this.multiple?"&multiple=true":"")+(this.sortable?"&sortable=true":"")})},selectMovie:function(A){if(!this.multiple){this.selectedMovies.push(A);this.onSelect();return false}if(!this.selectedMovies.contains(A)){this.selectedMovies.push(A);this.addPreview(A)}else{this.selectedMovies.remove(A);this.removePreview(A)}return false},addPreview:function(F){var C=F;if(F.startsWith("p_")){F=F.substring(2)}var E=$("sel_videoItem_"+F);var A="preview_"+F;var D=createElement("div",A,"videoItem");D.style.width="190px";D.style.overflow="hidden";var B=this.searchTag(E,"img","icon-publish");if(B){D.appendChild(B.cloneNode(true))}D.appendChild(this.searchTag(E,"p","thumb-image").cloneNode(true));D.appendChild(createElement("ul",null,null,this.searchTag(E,"li","video-title").cloneNode(true)));Event.observe(D,"click",function(){this.selectedMovies.remove(C);this.removePreview(C)}.bindAsEventListener(this));Event.observe(D,"mouseover",function(){Element.addClassName(D,"hover")}.bindAsEventListener(this));Event.observe(D,"mouseout",function(){Element.removeClassName(D,"hover")}.bindAsEventListener(this));$("Preview").appendChild(D);Element.removeClassName("sel_videoItem_"+F,"hover");Element.hide(E)},searchTag:function(D,B,C){D=$(D).firstChild;while(D){if(D.nodeType==1){if(D.tagName.toLowerCase()==B){if(!C||Element.hasClassName(D,C)){return D}}var A=this.searchTag(D,B,C);if(A){return A}}D=D.nextSibling}return null},removePreview:function(C){if(C.startsWith("p_")){C=C.substring(2)}var A="preview_"+C;var B=$(A);B.parentNode.removeChild(B);Element.show("sel_videoItem_"+C)},onSelect:function(){if(this.selectedMovies.length==0){skdialog.alert("ビデオを選択してください。",null,{title:"メールでシェア"});return false}var A=new Array();var C=false;for(var B=0;B<this.selectedMovies.length;B++){var D=this.selectedMovies[B];if(D.startsWith("p_")){C=true;A.push(D.substring(2))}else{A.push(D)}}this.clientOnSelect(A,C);return false},selectCurrentSellections:function(){for(var A=0;A<this.selectedMovies.length;A++){this.addPreview(this.selectedMovies[A])}},a:0};eyevio.setting={checkEdit:function(){if(!this._modified){return true}return confirm("この画面での設定変更が破棄されますが移動しますか？")},modified:function(A){A=$(A);if(A&&A.disabled==true){A.disabled=false;A.src=A.src.replace("disable","default")}this._modified=true}};eyevio.dialogModifyChecker={opened:function(){this._modified=false},checkEdit:function(){if(!this._modified){return true}return confirm("OK を押さないと反映されませんが移動しますか？")},modified:function(A){A=$(A);if(A&&A.disabled==true){A.disabled=false;A.src=A.src.replace("disable","default")}this._modified=true}};eyevio.messaging={showDetail:function(B,C,A){skdialog.show({title:"メッセージ : "+C,contentURL:"/ajax/dialog/messageDetail.do?messageId="+B+((A)?"&isReceive=true":"")})},openForm:function(A,C,B){skdialog.show({title:"メッセージ作成",contentURL:"/ajax/dialog/messageForm.do?memberId="+A+"&messageId="+C+"&isReceive="+B})},deleteMessage:function(B,A){skdialog.confirm("このメッセージを削除しますか？",function(){ajaxCall("/ajax/deleteMessage.do?messageId="+B+"&isReceive="+A,function(){location.reload()})})},send:function(A){skdialog.confirm("送信します。よろしいですか？",function(){ajaxPostForm(A)});return false}};eyevio.tutorial={onload:function(){if(getCookie("tutorialSection")){this._init()}},start:function(A){this.controller.start(A);return false},next:function(){this.controller.next();return false},skip:function(A){this.controller.skip(A);return false},close:function(){deleteCookie("tutorialSection");deleteCookie("tutorialSubSection");top.location.href="/";return false},ACTION_SKIP_BUTTON:1,ACTION_TOGGLE_ABOUT:2,ACTION_OPEN_FULLSCREEN:10,ACTION_CLOSE_FULLSCREEN:11,ACTION_EVAL_MOVIE:12,ACTION_ADD_SEARCH_CHANNEL:20,ACTION_TOGGLE_MY_CHANNEL:21,ACTION_ADD_MOVIE_TO_BOOKMARK:30,ACTION_ADD_CHANNEL_TO_SCRAPBOOK:31,ACTION_PUSH_UPLOAD_BUTTON:40,ACTION_DO_UPLOAD:41,ACTION_SETTING_AFTER_UPLOAD:42,ACTION_PUSH_MAIL_TAB:43,ACTION_SEND_SHARE_MAIL:44,ACTION_PUSH_BLOG_TAB:45,ACTION_CLOSE_BLOG_DIALOG:46,ACTION_CLOSE_UPLOAD_DIALOG:47,ACTION_CLOSE_CC_DIALOG:48,ACTION_CLOSE_SHAREMAIL_DIALOG:49,ACTION_OPEN_SHARE_FORM:50,ACTION_COMP_BLOG:51,ACTION_OPEN_DOWNLOAD_DIALOG:61,ACTION_START_DOWNLOAD_MBTK:62,ACTION_COMP_DOWNLOAD_MBTK:63,ACTION_CLOSE_DOWNLOAD_MBTK:64,ACTION_CONNECT_DOWNLOAD_DEVICE:65,ACTION_SELECT_DOWNLOAD_DEVICE:66,ACTION_COMP_DOWNLOAD:67,ACTION_CLOSE_DOWNLOAD_DIALOG:68,ACTION_TOGGLE_EYEVIO_CHANNEL:69,ACTION_PUSH_SAVE_EDIT_BUTTON:70,ACTION_PUSH_CC_TAB:71,ACTION_OPEN_EDIT_VIDEO:72,ACTION_DELETE_MOVIE:73,ACTION_ADD_CHANNEL:80,ACTION_COMP_EDIT_CHANNEL:81,ACTION_PUSH_BLOG_BUTTON:90,ACTION_SELECT_MOVIE:91,ACTION_OPEN_SETTING_BLOG:92,ACTION_COMP_SETTING_BLOG:93,ACTION_COMP_SEND_BLOG:94,notifyAction:function(actionId){if(getCookie("tutorialSection")){this.controller.notifyAction(actionId);if(actionId==this.ACTION_OPEN_FULLSCREEN){if(EyevioFlash&&EyevioFlash.manager&&EyevioFlash.manager.flDivEl){var left=Element.getWidth(EyevioFlash.manager.flDivEl)/2+140;eyevio.tutorial.hilight({id:"FlvPlayerDummy",left:left,bottom:20,absolute:true})}}else{if(actionId==this.ACTION_CLOSE_FULLSCREEN&&this.controller.currentScript){this._cancelHilight();var meta=eval("("+this.controller.currentScript+")");if(meta.onload){meta.onload()}}}}},setContent:function(scr,text){this._cancelHilight();this.setPopupPos(24,75);this.currentContents.innerHTML=text;var meta=eval("("+scr+")");Element.show("tutorial_next");Element.hide("tutorial_skip");if(meta.buttons){if(meta.buttons=="none"){Element.hide("tutorial_next")}else{if(meta.buttons=="skip"){Element.hide("tutorial_next");Element.show("tutorial_skip")}}}if(meta.onload){meta.onload()}},setPopupPos:function(D,E,F,C){var B=new Viewport();var A=0;var G=0;if(D||D==0){A=B.windowWidth-Element.getWidth(this.popup)-D}if(E||E==0){G=E}if(F||F==0){A=F}if(C||C==0){G=B.windowHeight-Element.getHeight(this.popup)-C}Element.setStyle(this.popup,{left:A+"px",top:G+"px"})},hilight:function(B,A){if(A){this.hilightCursor.firstChild.src="/img/tutorial_cursor_reverse.png";if(getIEVersion()==6){this.hilightCursor.style.filter="progid:DXImageTransform.Microsoft.AlphaImageLoader( sizingMethod=crop, src='/img/tutorial_cursor_reverse.png');"}}else{this.hilightCursor.firstChild.src="/img/tutorial_cursor.png";if(getIEVersion()==6){this.hilightCursor.style.filter="progid:DXImageTransform.Microsoft.AlphaImageLoader( sizingMethod=crop, src='/img/tutorial_cursor.png');"}}if(this.hilightTarget){Element.show(this.hilightCursor)}this.hilightOptions=B;if(location.href.indexOf("/tools")!=-1){this.hilightTarget=$("toolIframe").contentWindow.document.getElementById(this.hilightOptions.id)}else{this.hilightTarget=$(this.hilightOptions.id)}if(!this.hilightTarget){this.currentContents.innerHTML='<p class="tutorial-read">この画面はチュートリアルで想定している画面と異なります。<br />恐れ入りますが、「戻る」を押して、もう一度指示に従ってみてください。</p><a href="javascript:void(0)" onclick="/*eyevio.tutorial.prev(); */history.back()"><img class="btn-back" alt="戻る" title="戻る" src="/img/btn_back_default.gif" onmouseover="img_change(this, \u0027/img/btn_back_hover.gif\u0027)" onmouseout="img_restore(this)" /></a>';Element.hide("tutorial_next");Element.hide("tutorial_skip");return }this._setCursorPos(true);this._animPos=1;this._delta=-0.08;if(!this.timer){this.timer=setTimeout(this._anim.bind(this),100)}},_cancelHilight:function(){Element.hide(this.hilightCursor);if(this.timer){clearTimeout(this.timer)}7;if(this.hilightTarget){if(!Prototype.Browser.IE){Element.setStyle(this.hilightTarget,{opacity:1})}else{this.hilightTarget.style.filter="alpha(opacity=100)"}}this.timer=null;this.firstHilightOptions=null;this.secondHilightOptions=null},_setCursorPos:function(G){var F=Position.cumulativeOffset(this.hilightTarget);var E=Element.getDimensions(this.hilightTarget);var B=Element.getDimensions(this.hilightCursor);var A=new Viewport();var D={};if(this.hilightOptions.left){D.left=((this.hilightOptions.absolute?0:F[0])+this.hilightOptions.left)}if(this.hilightOptions.top){D.top=((this.hilightOptions.absolute?0:F[1])+this.hilightOptions.top-B.height)}if(this.hilightOptions.right){D.left=((this.hilightOptions.absolute?A.windowWidth:F[0]+E.width)-this.hilightOptions.right)}if(this.hilightOptions.bottom){D.top=((this.hilightOptions.absolute?A.windowHeight:F[1]+E.height)-this.hilightOptions.bottom-B.height)}if(D.left==this.hilightCursor.offsetLeft&&D.top==this.hilightCursor.offsetTop){return }Element.setStyle(this.hilightCursor,{left:D.left+"px",top:D.top+"px"});if(G){var C=D.top-A.windowHeight+B.height+30;if(C>0){window.scrollBy(0,C);Element.setStyle(this.popup,{top:this.popup.offsetTop+C+"px"})}Element.setStyle(this.hilightCursor,{opacity:1,visibility:"visible",display:"block",zIndex:1002})}},_anim:function(){if(location.href.indexOf("/tools")!=-1){$("toolIframe").contentWindow.document.getElementById(this.hilightOptions.id)}else{if(!$(this.hilightOptions.id)||!this.hilightTarget){if(!$(this.hilightOptions.id)){Element.hide(this.hilightCursor);this.hilightTarget=null;this.timer=setTimeout(this._anim.bind(this),100);return }else{Element.show(this.hilightCursor)}}this.hilightTarget=$(this.hilightOptions.id)}if(getIEVersion()!=6){Element.setStyle(this.hilightTarget,{opacity:this._animPos});Element.setStyle(this.hilightCursor,{opacity:this._animPos})}else{this.hilightTarget.style.filter="alpha(opacity="+this._animPos*100+")";if(this._animPos<0.65&&this.hilightCursor.style.visibility=="visible"){this.hilightCursor.style.visibility="hidden"}if(this._animPos>0.65&&this.hilightCursor.style.visibility=="hidden"){this.hilightCursor.style.visibility="visible"}}this._setCursorPos();this._animPos+=this._delta;if(this._animPos>1){this._animPos=1;this._delta=-this._delta}if(this._animPos<0.5){this._animPos=0.5;this._delta=-this._delta}this.timer=setTimeout(this._anim.bind(this),100)},_init:function(){try{var B=window.parent;if(!B||!B.frames.controller||!B.frames.controller.eyevio||(B.frames.controller.eyevio.tutorialController.currentMeta.initialURL=="/tutorialTop.do"&&location.protocol+"//"+location.host+"/tutorialTop.do"!=location.href)){deleteCookie("tutorialSection");if(top.location.href!=location.href){top.location.href=location.href}return }}catch(A){deleteCookie("tutorialSection");return }this.controller=B.frames.controller.eyevio.tutorialController;var A=createDiv();A.innerHTML=this.controller.getPopupHTML();A=firstChildElement(A);document.body.appendChild(A);this._createWindow();this.actions=$("TutorialActions");this.currentContents=$("TutorialContents");this.hilightCursor=$("TutorialFloaterCursor");this.controller.onloadTarget()},_createWindow:function(){this.popup=$("TutorialFloaterWindow");this.title=$("TutorialFloaterTitle");this.title.style.cursor="move";if(Prototype.Browser.IE&&getIEVersion()==6){this.popup.style.height="150px";this.popup.firstChild.style.height="137px"}var A;var B;new Draggable(this.popup,{handle:this.title,starteffect:function(){A=document.documentElement.scrollWidth;B=document.documentElement.scrollHeight},snap:function(C,D){if(C<0){C=0}if(C>A-this.popup.offsetWidth){C=A-this.popup.offsetWidth}if(D<0){D=0}if(D>B-this.popup.offsetHeight-15){D=B-this.popup.offsetHeight-15}return[C,D]}.bind(this)});Event.observe(this.title,"mousedown",function(){new Effect.Opacity(this.popup,{duration:0.2,from:Element.getOpacity(this.popup),to:0.4})}.bind(this));Event.observe(this.title,"mouseup",function(){new Effect.Opacity(this.popup,{duration:0.2,from:Element.getOpacity(this.popup),to:1})}.bind(this))},includeTutorial:function(D,B){if($("TutorialFloaterBox")){Element.remove("TutorialFloaterBox")}var A='<div id="TutorialFloater">	<div id="TutorialFloaterWindow" style="z-index: 1002;"><div class="inner">			<h2 id="TutorialFloaterTitle" style="position: relative">チュートリアル</h2>			<ul id="TutorialActions" class="list-action">				<li class="quit"><a href="javascript:void(0)" onclick="Element.remove(\'TutorialFloaterBox\')">終了</a></li>				<li id="tutorial_next" class="next" style="z-index: 1001"><a href="/tutorial/'+D+'">次へ</a></li>			</ul>			<div id="TutorialContents" class="content" style="position: relative">				<h3><strong>＜</strong>チュートリアル開始<strong>＞</strong></h3>				<p class="tutorial-read">					この枠で表示される指示に従って、チュートリアルを進めましょう。<br />					〔次へ〕ボタンをクリックして先に進んでください。<br />  				</p>			</div>		</div>		<div class="footer"></div>	</div></div>';var C=createElement("div");C.id="TutorialFloaterBox";document.body.appendChild(C);Element.update(C,A);this._createWindow();this.setPopupPos(null,B.offsetTop,B.offsetLeft)}};eyevio.top={set:function(B,A){if(A){Element.removeClassName(B,"clickable");Element.addClassName(B,"tab_selected")}else{Element.removeClassName(B,"tab_selected");Element.addClassName(B,"clickable")}},selectChannelTab:function(B,A){this.set("tab_channel_eyevio",B.id=="tab_channel_eyevio");this.set("tab_channel_shared",B.id=="tab_channel_shared");this.set("tab_channel_user",B.id=="tab_channel_user");new Ajax.Updater("channels_table","/frag/top_channellist.do?type="+A,{onComplete:function(){ellipsisAll("channels_table")}});$("channel_list_href").href="/channels/"+A.replace("_for_top","")},selectNewTab:function(B,A){this.set("tab_recent_all",B.id=="tab_recent_all");this.set("tab_recent_hd",B.id=="tab_recent_hd");new Ajax.Updater("new_table","/frag/top_videolist.do?channelId="+A,{onComplete:function(){ellipsisAll("new_table")}});$("new_list_href").href="/channel_movies/"+A},selectRankingTab:function(B,A){this.set("tab_ranking_all",B.id=="tab_ranking_all");this.set("tab_ranking_hd",B.id=="tab_ranking_hd");this.set("tab_ranking_comment",B.id=="tab_ranking_comment");this.set("tab_ranking_ch",B.id=="tab_ranking_ch");if(A!="channel_views_weekly"){new Ajax.Updater("ranking_table","/frag/top_videolist.do?channelId=special_ranking_"+A,{onComplete:function(){ellipsisAll("ranking_table")}});$("ranking_list_href").href="/ranking/"+A}else{new Ajax.Updater("ranking_table","/frag/top_channellist.do?type=ranking_views",{onComplete:function(){ellipsisAll("ranking_table")}});$("ranking_list_href").href="/channels/ranking_views"}},a:0};
