/* CSS・スタイルシート質問スレッド【48px】 */

このエントリーをはてなブックマークに追加
182Name_Not_Found
Gyaoという無料の動画配信サービスを観るときに、CM時の音量調整や右クリックで
全画面表示を可能にするスタイルシートが紹介されていましす。大画面(高ビットレー
ト)だと負荷がスゴイので、低ビットレートで鑑賞したいのですが、その場合は小画面
でしか鑑賞できません。

そのスタイルシートとは>>183の「CM時の音量調整」と>>184の「再生画面で右クリッ
クを有効にする」なのですが、私は低ビットレート(小画面)で右クリックを有効にして、
全画面表示で鑑賞したいのです。

しかし>>184のみでは上手く動作せず、>>183も記述してやらないと希望の動作をしま
せん。CMの音量調整は不要なので、右クリックのみ有効にする記述で、削る部分が
分かる方がいらっしゃれば御教示ください。

●Gyao
http://www.gyao.jp/
183CMの時に音量を調整する:2005/10/18(火) 07:34:02 ID:???
object { behavior:expression(
function(element){
runtimeStyle.behavior = "none";

switch(element.classid.toUpperCase()) {
case "CLSID:6BF52A52-394A-11D3-B153-00C04F79FAA6" : //Windows Media Player
element.enableContextMenu=true;

if(window.location.toString().match("^http://www.gyao.jp")) {
var isAdBefore=false, volume = 100, cmvolume = 10;
element.attachEvent("OpenStateChange",function(newstate){
if(newstate==13 /*MediaOpen*/ ) {
var info = currentMedia.getItemInfo("WMS_CONTENT_DESCRIPTION_PLAYLIST_ENTRY_URL");
var keysline = info.split(":");
var keys = new Object;
for( var i = 0; i < keysline.length; i++ ) {
var key = keysline[i].split("=");
keys[key[0]] = key[1];
}
if(isAdBefore) { cmvolume = element.settings.volume } else { volume = element.settings.volume }
isAdBefore = keys["AdvId"];
element.settings.volume = ( keys["AdvId"] ) ? cmvolume : volume;
//element.settings.mute =( keys["AdvId"] ) ? true : false;
}
});
}
break;
}
}(this)
);
}
184再生画面で右クリックを有効にする:2005/10/18(火) 07:34:55 ID:???
script { behavior:expression(
function(element){
runtimeStyle.behavior = "none";

if(window.location.toString().match("^http://www.gyao.jp")) {
if(element.event=="click()") {
element.event="";
}
}
}(this)
);
}

html { behavior:expression(
function(element){
if(window.location.toString().match("^http://www.gyao.jp")){
function clear(e) {
e.onkeydown=e.onkeyup=e.onkeypress=
e.ondblclick=e.ondragstart=
e.oncontextmenu=e.onselectstart=null;
}
if(window.document.body) {
clear(window);clear(window.document);clear(window.document.body);
clear(element);clear(window.document.documentElement);
runtimeStyle.behavior = "none";
}
}
}(this)
);
}