让你的AIR程序,被其他应用调用。

来源:互联网 发布:域名注册最便宜 编辑:程序博客网 时间:2024/06/05 18:55

在Android里,很简单

在iOS里需要做如下设置。

<iPhone>        <InfoAdditions>        <![CDATA[<key>UIDeviceFamily</key><array><string>2</string></array><key>CFBundleURLTypes</key> <array>   <dict>        <key>CFBundleURLSchemes</key>        <array>            <string>example</string>       </array>        <key>CFBundleURLName</key>        <string>com.example</string>    </dict></array>]]></InfoAdditions>        <requestedDisplayResolution>high</requestedDisplayResolution></iPhone>

在你的AIR程序里,接收调用程序传递的参数。应该加上

 

NativeApplication.nativeApplication.addEventListener(InvokeEvent.INVOKE, onInvoke);private function onInvoke(e:InvokeEvent):void{var arg:Array = e.arguments;}


 





原创粉丝点击