易截截图软件、单文件、免安装、纯绿色、仅160KB

flex 右键菜单管理工具类

/*============使用==========*/
var contextmenu:ContextMenuManager=new ContextMenuManager();
contextmenu.add("最大化",menuHandle);//menuHandle处理函数
/**==================ContextMenuManager.as==========================*/
package file
{
    import flash.display.InteractiveObject;
    import flash.events.*;
    import flash.errors.IllegalOperationError;
    import flash.ui.*;
    import flash.utils.getQualifiedClassName;
    public class ContextMenuManager extends EventDispatcher
    {
        protected var menu:ContextMenu;
        protected var target:InteractiveObject;
        public function ContextMenuManager(target:InteractiveObject,hideBuiltInItems:Boolean=true)
        {
            this.target=target;
            menu=new ContextMenu();
            if(hideBuiltInItems)
            {
                menu.hideBuiltInItems();
            }
            this.target.contextMenu=menu;
            menu.addEventListener(ContextMenuEvent.MENU_SELECT,passEvent);
        }
        public function add(caption:String,handler:Function,separatorBefore:Boolean=false,enabled:Boolean=true,visible:Boolean=true):ContextMenuItem
        {
            var result:ContextMenuItem=createItem(caption,handler,separatorBefore,ena


相关文档:

Flex组件(对话框)

java开发的总想尽快把flex和java结合起来,我也是,但这容易忽视一些基础的东西,刚把flex和java整合的第一步做完,忽然想在flex页面中弹出个对话框,不知道怎么写了,网上查了半天才出来.
原来这一句话就搞定了
Alert.show(content,title,flags,parent,closeHandle,iconClass,defaultButtonFlag);
以下是网上找到资料,供参考. ......

flex 中GML转换

package org.openscales.core.format
{
 import flash.utils.getQualifiedClassName;
 import flash.xml.XMLNode;
 import org.openscales.core.Util;
 import org.openscales.core.feature.Feature;
 import org.openscales.core.geometry.Collection;
 import org.openscales.core. ......

FABridge教程(Flex+Ajax) 2

使用js来操作flex
首先在fademo.mxml中声明一个button,并添加一个btnClick方法:
<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="l ......

Flex no.2

--------------ex2_01_solution  选取时间-----------------------
 ...
   private function dateChangeHandler():void
   {
    // The Alert.show() message displays a static string plus the selected date in the startDate control
   ......

常用的Flex代码总结

常用的Flex代码总结
1.刷新浏览器

  navigateToURL(new URLRequest("javascript:location.reload();"),"_self")

  2.关闭浏览器

  navigateToURL(new URLRequest("javascript:window.close()"),"_self");

  3.打开一个新浏览器窗口

  navigateToURL(new URLRequest('ht ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号