zoukankan      html  css  js  c++  java
  • [ActionScript 3.0] as3启动QQ

    import flash.html.HTMLLoader;
    import flash.net.URLLoader;
    import flash.net.URLRequest;
    import flash.events.MouseEvent;
    
    var qqIcon:Loader = new Loader();
    qqIcon.contentLoaderInfo.addEventListener(Event.COMPLETE,onLodrEnd);
    qqIcon.load(new URLRequest("http://wpa.qq.com/pa?p=1:879255681:7"));//"http://wpa.qq.com/pa?p=2:" + qq + ":41?" + Math.random(); 
    qqIcon.addEventListener(MouseEvent.CLICK,onQQIConClick);
    qqIcon.addEventListener(MouseEvent.MOUSE_OVER,onQQIConOver);
    qqIcon.addEventListener(MouseEvent.MOUSE_OUT,onQQIConOut);
    
    function onLodrEnd(event:Event):void
    {
    this.addChild(qqIcon);
    }    
    function onQQIConClick(event:MouseEvent):void
    {
        //navigateToURL(new URLRequest("tencent://message/?Menu=yes"));//没登录会打开登录窗口
        navigateToURL(new URLRequest("http://wpa.qq.com/msgrd?v=3&uin=" + 879255681 + "&site=qq&menu=yes"));//qq如果登录,会打开好友879255681号码的窗口,没登录会打开登录窗口
        
    }
    function onQQIConOver(e:MouseEvent):void{
        Mouse.cursor=MouseCursor.BUTTON; 
    }
    function onQQIConOut(e:MouseEvent):void
    {
        Mouse.cursor=MouseCursor.ARROW; 
    }
  • 相关阅读:
    反射工具类
    序列化反序列化工具类
    开发SCM系统笔记001
    卸载Oracle
    log4j日志级别
    类加载器与methodinterceptor接口
    hibernate 查询、二级缓存、连接池
    Hibernate缓存、组件、继承映射
    Hibernate映射1
    Hibernate配置文件
  • 原文地址:https://www.cnblogs.com/frost-yen/p/6432930.html
Copyright © 2011-2022 走看看