actionscript-3

AS3 bug? Newline automatically entered after css tag

元气小坏坏 提交于 2020-01-04 06:30:50
问题 I am rendering a TextField (Flash CS5) with the following css and html properties : css = "a {font-weight: bold;} fu {color: #00A0A0;}" wordWrap = true multiline = true html = <![CDATA["Phoenicians were pioneering artisans and ingenious craftsmen… They developed the technique behind the production of transparent glass… Their innovation spread around the globe throughout the past centuries… <fu>WE AIM TO CARRY ON WITH THE INNOVATION</fu>"]]> The last QUOTE is rendered in a line BELOW "WE AIM

C# / ActionScript with AxShockwaveFlash

让人想犯罪 __ 提交于 2020-01-04 05:54:09
问题 I am new to ActionScript and am trying to communicate between AS and C#. Every tutorial/explanation I find seems to be exactly the same, but I simply cannot get it to work. callFunction throws a COM exception ("E_FAIL"), and when I try calling ExternalInterface.call() from the AS, it never seems to. I've gotten this to work in JavaScript/HTML, but I'm out of ideas for C#; I suspect I'm doing something wrong/not allowed in my AS. I compile the AS file with Adobe Flex 4.6 and mxmlc. Edit: Just

Skipping certain files/classes when using asdoc

泪湿孤枕 提交于 2020-01-04 05:52:28
问题 For some reasons, asdoc seems to be only good at 'excluding' classes but not 'skipping', which means all the files will always be walked through and examine for errors. Is there a way to make asdoc really 'skip' some certain files? So it can bypass some already known problematic files and still generate the necessary docs gracefully. Thanks. 回答1: We haven't found a way of having asdoc skip files, but we have got it working by only providing a whitelist of what files we do want parsed. You

Skipping certain files/classes when using asdoc

做~自己de王妃 提交于 2020-01-04 05:52:04
问题 For some reasons, asdoc seems to be only good at 'excluding' classes but not 'skipping', which means all the files will always be walked through and examine for errors. Is there a way to make asdoc really 'skip' some certain files? So it can bypass some already known problematic files and still generate the necessary docs gracefully. Thanks. 回答1: We haven't found a way of having asdoc skip files, but we have got it working by only providing a whitelist of what files we do want parsed. You

Parse string pattern into Date in Flex

☆樱花仙子☆ 提交于 2020-01-04 05:27:30
问题 Is there some way in flex to parse strings to date. I want it to support custom formats similar to 'dateformatter'. Using 'dateformatter' class we can parse date object in various string formats as specified by 'formatString property'. I want it other way round, from string to date. The parse method 'Date.parse(my_string)' does string parsing but for a very limited set of formats. Can't we have something similar to following, where user can specify his/her own formats. someformatter

Sound keeps playing after external swf was unloaded

假装没事ソ 提交于 2020-01-04 04:43:26
问题 I have a flash application, some kind of a play-list that loads external SWF video player (I don't have code access to that external file), so users can watch the video or skip to another one. When user switches to another video new SWF file is being loaded. The problem : If user didn't finish watching the video and skips to the next then I unload previous SWF file ( unloadAndStop() ) and load a new one. And because the previous SWF was playing it is not actually unloaded, it is still playing

AS3: Analyzing sound spectrums one by one, one channel at once

左心房为你撑大大i 提交于 2020-01-04 04:32:26
问题 I know the SoundMixer.computeSpectrum and Sound.extract() methods , but those methods deal with the total sound output. Instead, is there a way to deal with every single SoundChannel, so as to provide a graphical visualization of each of them? 回答1: I'm afraid that's not possible. In fact, the computeSpectrum method doesn't even compute your own channels but analyses every sound the Flash plugin catches. This can be annoying when the sounds are playing on a different location which will cause

AS3: Analyzing sound spectrums one by one, one channel at once

孤人 提交于 2020-01-04 04:32:08
问题 I know the SoundMixer.computeSpectrum and Sound.extract() methods , but those methods deal with the total sound output. Instead, is there a way to deal with every single SoundChannel, so as to provide a graphical visualization of each of them? 回答1: I'm afraid that's not possible. In fact, the computeSpectrum method doesn't even compute your own channels but analyses every sound the Flash plugin catches. This can be annoying when the sounds are playing on a different location which will cause

Flash Audio Lag in Google Chrome

自古美人都是妖i 提交于 2020-01-04 03:49:31
问题 I'm currently working on a flash game and, at least on my machine, the audio seems to lag by a fraction of a second in Chrome, but not in IE or FF. This isn't a huge deal, the game is still playable, but it's a little bit annoying. Is there anything I can do from a development standpoint to fix this issue or is it something the user would have to fix? Edit: I've now tested it on two other machines and the same thing happened. The audio is delayed in chrome but not Firefox or IE. Edit 2: I've

open local files in AS3

╄→гoц情女王★ 提交于 2020-01-04 02:35:10
问题 How do i open file and get its content as a ByteArray in AS3. I saw examples, using FileStream & File classes from flex.filesystem, but the doc says it's for AIR only. Thanks, Nava 回答1: You can try either URLLoader with content set for binary, or use URLStream. What do you need to load ? 回答2: You can use a FileReference object to browse for a file and then access the raw bytes via the "data" property on the FileReference when the "complete" event is dispatched. 回答3: Flex security prevents