当前位置:编程学习 > JS >>

关于flash全屏脚本问题

function onResize()
{
    bg_mc._x = bg_mc._y = 5;
    var _loc1 = Stage.width > 200 ? (Stage.width) : (200);
    var _loc2 = Stage.height > 100 ? (Stage.height) : (100);
    bg_mc._width = _loc1 - 10;
    bg_mc._height = _loc2 - 10;
    lbl_txt._x = _loc1 - 5 - lbl_txt._width;
    lbl_txt._y = 5;
} // End of the function
function getPlayerVersion()
{
    var _loc2 = System.capabilities.version;
    if (_loc2)
    {
        _loc2 = getVersion();
    } // end if
    var _loc1 = _loc2.split(" ");
    _loc1 = _loc1[1].split(",");
    return (Number(_loc1[0]) + Number(_loc1[1]) / 100 + Number(_loc1[2]) / 10000 + Number(_loc1[3]) / 1000000);
} // End of the function
function fullScreenHandler()
{
    if (version < 8)
    {
        getURL("javascript:fullScreen();");
    }
    else if (version < 9.001860E+000)
    {
        flash.external.ExternalInte易做图ce.call("fullScreen", null);
    }
    else
    {
        Stage.displayState = "fullScreen";
    } // end else if
} // End of the function
function normalScreenHandler()
{
    if (version < 8)
    {
        getURL("javascript:normal();");
    }
    else if (version < 9.001860E+000)
    {
        flash.external.ExternalInte易做图ce.call("normal", null);
    }
    else
    {
        Stage.displayState = "normal";
    } // end else if
} // End of the function
stop ();
var version = getPlayerVersion();
ver_txt.text = System.capabilities.version;
Stage.scaleMode = "noScale";
Stage.align = "TL";
Stage.addListener(this);
onResize();
full_btn.onClick = function ()
{
    if (full_btn.getLabel() == "全屏效果")
    {
        fullScreenHandler();
        full_btn.setLabel("退出全屏");
    }
    else
    {
        normalScreenHandler();
        full_btn.setLabel("全屏效果");
    } // end else if
};

这是一段flash的脚本我如果想让他在运行5秒之后自动进入全屏要怎么些

CopyRight © 2022 站长资源库 编程知识问答 zzzyk.com All Rights Reserved
部分文章来自网络,