如何使用Android应用内定制Flash播放器 [英] How to use custom flash player inside android app

查看:128
本文介绍了如何使用Android应用内定制Flash播放器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个自定义的flash播放器(如.swf文件)。是否可以使用自定义的flash播放器在我的Andr​​oid应用?如果是这样,我怎么能做到这一点?例如链接是多少AP preciated。

I've a custom flash player(as .swf file). Is it possible to use that custom flash player on my android app? If it so, how could i do that? Example links are much appreciated.

感谢。

推荐答案

您必须创建嵌入SWF文件的HTML文件。看到这里 http://pastebin.com/BYrfKmea 之后,样品可以使其在三种不同的方式。

You have to create an html file with embedded swf file. See sample here http://pastebin.com/BYrfKmea After that you can make it in three different ways


  • 您可以把HTML和SWF文件的资产文件夹,并尝试在的WebView mWebView.loadUrl打开它(文件: /// android_asset / player.html); 。这种方法主要是disadvatage闪光灯未在的WebView工作有时。

  • You can put html and swf files in assets folder and try opening it in a WebView by mWebView.loadUrl("file:///android_asset/player.html");. Main disadvatage of this method is flash is not working in WebView sometimes.

将HTML和SWF文件的资产文件夹中。然后他们编程复制到SD卡上。如何做到这里找到<一个href=\"http://stackoverflow.com/questions/4447477/android-how-to-copy-files-in-assets-to-sdcard\">Android:如何复制文件'资产'到SD卡然后在浏览器中调用打开复制的文件 startActivity(新意图(Intent.ACTION_VIEW,Uri.parse(文件:/// MNT / SD卡/ player.html)));

Put html and swf files in assets folder. Then programmatically copy them to SD card. How to do that find out here Android: How to copy files in 'assets' to sdcard? Then open copied file in browser by calling startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("file:///mnt/sdcard/player.html")));

将HTML和SWF由 startActivity(新意图(Intent.ACTION_VIEW,Uri.parse(http://www.yoursite.com一个Web服务器,然后打开浏览器上FLES /player.html))); 。这种方法的缺点是,你需要互联网连接和web服务器准备好高负载。

Place html and swf fles on a web-server and open in browser by startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("http://www.yoursite.com/player.html")));. Disadvantage of this method is that you need internet connection and a web-server ready for high-load.

这篇关于如何使用Android应用内定制Flash播放器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆