flash

AS3 Instantiate Class From External SWF

故事扮演 提交于 2019-12-29 07:52:20
问题 I was chatting with my buddy about this, he is convinced you can do this and says he has done it, but I cannot get this to work. I am wondering if it is even possible at all. I tried typing a var as a Class that is within the externally downloaded SWF and then making an instance but no can do. some code private static function onCompleteHandler(e:Event) { dashboardObject = e.target.content; // registerClassAlias("Dashboard", ); doesnt work var dash:Class = getDefinitionByName("Dashboard") as

What does “install Flash plugin” in WebView mean?

耗尽温柔 提交于 2019-12-29 07:52:17
问题 In a small WebView app I wrote, I am able to load YouTube and see the picture the represents a video clip, with the familiar right-pointing arrow that is supposed to start playing the video: But... when I touch that arrow, nothing happens (the video is NOT played). I did enable the plugins setting in WebView, but that didn't help: mWebView.getSettings().setPluginsEnabled(true); So, I searched for more clues about how to make Flash (YouTube) run embedded in my WebView and I found the following

Get and parse JSON in Actionscript

心不动则不痛 提交于 2019-12-29 07:42:29
问题 What I want to do is make a get request to this URL: http://api.beatport.com/catalog/3/most-popular, which should return some JSON and then parse out certain information from it. How would I go about doing this in Actionscript 3? I'm more concerned with figuring out how to get the data to feed to a JSON parser rather than parsing the JSON, since there seem to be plenty of questions about parsing JSON. The reason I want to do this in AS3 is that I have a 3D flash visualization set up and I

How can I get the background color of a loaded swf file?

£可爱£侵袭症+ 提交于 2019-12-29 07:22:10
问题 I'm loading an swf file into my main application using URLLoader, I want to get the background color of the loaded swf file. ( I heard that one solution wold be reading the byte code of the loaded swf ) 回答1: Yes, You need to look into binary swf data. Here is brief description of swf format. And this is a little detail about different kind of tags. Your requirement is to find out SetBackgroundColor tag(tag type = 9), which commonly is either first or second tag of the swf. Bytes in swf file

How can I get the background color of a loaded swf file?

笑着哭i 提交于 2019-12-29 07:21:31
问题 I'm loading an swf file into my main application using URLLoader, I want to get the background color of the loaded swf file. ( I heard that one solution wold be reading the byte code of the loaded swf ) 回答1: Yes, You need to look into binary swf data. Here is brief description of swf format. And this is a little detail about different kind of tags. Your requirement is to find out SetBackgroundColor tag(tag type = 9), which commonly is either first or second tag of the swf. Bytes in swf file

Flash - AJAX call

佐手、 提交于 2019-12-29 06:59:14
问题 I want to call a web page from Flash and use the data returned from it (either in plain text or XML). I see with the NetConnection you can connect to a web service, but I just want to call a plain old web page. It seems like I managed to do this a while back, but for the life of me, I can't find the answer on the web. Does anyone know what the function / code is to call a web page in Flash and get the data back? Thanks, 回答1: All you need to do is use a URLLoader. var urlRequest:URLRequest=

How do you load a bitmap file into a BitmapData object?

谁说我不能喝 提交于 2019-12-29 05:08:49
问题 In Flash, the BitmapData object can be used to store bitmaps in RAM, you can later draw them to a MovieClip using the beginBitmapFill() method. How do you load an external bitmap file (.jpg) into a BitmapData object? Even AS3 code would be helpful. 回答1: AS3 code to load a PNG and "get" its bitmapData var bitmapData:BitmapData; var loader:Loader = new Loader(); loader.contentLoaderInfo.addEventListener(Event.COMPLETE, onComplete); loader.load(new URLRequest("../lib/img.png")); function

How to Enable Flash Plugin in Webview?

╄→гoц情女王★ 提交于 2019-12-29 04:54:14
问题 How to Enable Flash Plugin in Webview Browser? 回答1: You just need to enable the plugins for the webview, like this : WebView mWebView = (WebView) findViewById(R.id.WebView01); mWebView.getSettings().setPluginsEnabled(true); I think you also need Flash to be installed, like in Android 2.2 and above. Hope this helps. This method is now deprecated, I'll try to explain this more in detail. See here 回答2: I believe that you can WebSettings webSettings = myWebView.getSettings(); webSettings

Convert SWF to PNG

一个人想着一个人 提交于 2019-12-29 04:43:08
问题 I'd like to be able to take a 1-frame SWF file and convert it to PNG through PHP. I'm okay with using command-line tools to get this done. How could I go about doing this? I found an ActiveX library, but that seems like one too many layers. I also see that Gnash seems to have a PNG output class, but I can't figure out how to get to that from the command line without doing some deep coding of my own. Are there any other clever solutions available? Thanks! EDIT: To clarify, this is not a one

Adding unobtrusive progress bar to old-school file uploads

£可爱£侵袭症+ 提交于 2019-12-29 03:12:32
问题 You all know the new generation of fancy, mostly Flash-based file uploaders like SWFUpload that can show a progress bar while uploading - a great improvement especially for shaky and low-bandwidth connections. However, these uploaders all bring their own logic of how to handle uploads on the client side. I am looking for an unobtrusive way to "fancify" existing, classical file uploads, i.e. introducing a progress bar to normal file upload forms . Due to the architecture of uploading files,