简体   繁体   English

如何在Flex 4项目中将AS类设置为默认应用程序

[英]How to set an AS class as Default Application in Flex 4 Project

I'm currently working on a Flex 4 Project where I have several MXML files and a couple of AS classes. 我目前正在研究Flex 4项目,其中有几个MXML文件和几个AS类。 Due to the type of project the "Default Application" seems to be also an MXML instead of an AS3 class and I'm required to have the later. 由于项目类型的原因,“默认应用程序”似乎也是MXML而不是AS3类,因此我必须拥有后者。

Long story short, is it possible to set a given AS class as Default Application? 长话短说,是否可以将给定的AS类设置为默认应用程序? if not, is there any workaround? 如果没有,是否有任何解决方法?

Thanks in advance, 提前致谢,

Aldo 阿尔

I did it for Flex3/Eclipse, and i think Same For Flex4 in FlashBuilder/eclipse 我为Flex3 / Eclipse做到了,我认为FlashBuilder / eclipse中的Flex4相同

First you need to modify file " .actionScriptProperties " located in project root to add AS3 File as Application if your app name is AsApplication.as add tag under 首先,如果您的应用程序名称为AsApplication.as下的添加标记,则需要修改位于项目根目录中的文件“ .actionScriptProperties ”,以将AS3文件添加为应用程序。 if you have MXML App they would be listing here. 如果您有MXML App,它们将在这里列出。

<application path="AsApplication.as"/>

as

<applications>
    <application path="AsApplication.as"/>
</applications>

now its visible in project properties Set it as DEFAULT 现在,它在项目属性中可见将其设置为DEFAULT

在此处输入图片说明

Hopes that helps 希望能有所帮助

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM