【问题标题】:click.TAG from as2 to as3click.TAG 从 as2 到 as3
【发布时间】:2012-01-11 11:38:04
【问题描述】:

我需要帮助将 AS2 click.TAG 转换为 as3。有人可以帮忙吗? :)

as2 代码:

on (release) {
if (_root.clickthru==undefined&&  _root.clickTag) {
 _root.clickthru = _root.clickTag;
 }
if (_root.clickthru==undefined&&  _root.clickTAG) {
 _root.clickthru = _root.clickTAG;
}
if ( _root.clickTarget ==undefined) {
 _root.clickTarget = "_blank";
}

getURL(_root.clickthru, _root.clickTarget); }

【问题讨论】:

    标签: actionscript-3


    【解决方案1】:
    var paramObj:Object = LoaderInfo(this.root.loaderInfo).parameters;
    var clickTag:String = String(paramObj["clickTag"]);
    
    button_btn.addEventListener( MouseEvent.CLICK, openBanner, false, 0, true);
    
    function openBanner(event: MouseEvent) : void { 
    
       flash.net.navigateToURL(new URLRequest( clickTag ), "_blank"); 
    
    }
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2018-04-19
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多