apache-flex

AS3: removing objects by array item reference

断了今生、忘了曾经 提交于 2019-12-25 02:11:33
问题 I am trying to add some Sprite objects as the contents of an array, and I would like to be able to "clear" them from the stage. I would assume that if there are loaders involved, I need to do _imgArray[i].close(); _imgArray[i].unload(); And if I am using a sprite, I can do: removeChild(_imgArray[i]); None of the above work. WHY??? For an example and/or description of how I am setting this up, see Joel's post here ...but note that he hasn't included a reference for deleting them from view.

Flex Accessiblity - Reading out a label/text

假如想象 提交于 2019-12-25 01:55:31
问题 I need to make a small app accessible to screen reader. I'm managing to make buttons accessible, but I would also like to have a section of text accessible by screen readers so that users can hear what the text says. I can't seem to work out how to do this.. I've tried various text controls and set them as focusEnabled, tabEnabled, i've set the accessibility* attributes too but it never seems to work, I cannot tab to a text label and hear the content. I'm honestly a little new to accessiblity

Get Full Exception Error with Flex

一世执手 提交于 2019-12-25 01:49:50
问题 I can't use trace because I'm not using an Adobe IDE and when I try to view my exception errors, I can't seem to get the full error message, I only seem to get the "errorID". For example, if I had a 1069 error, I should see something like: Error #1069: Property data not found on X and there is no default value. But instead I see this... ReferenceError: Error #1069 This is my code... try { //error gets thrown here } catch(e:Error) { extTrace('Error: '+e.toString());//I also tried e.message, e

Flex 4 TLF and embedded font loaded as a module not working

两盒软妹~` 提交于 2019-12-25 01:47:12
问题 this problem is really killing me so any help will be really great :) I have a flex 4 application that loads a flex module. In this module I 'register' a bunch of fonts. I have a Spark textArea in this module that wants to use one of these fonts via its text flow which is created using: textArea.textFlow = TextConverter.importToFlow(htmlText, TextConverter.TEXT_FIELD_HTML_FORMAT); I 'register' the font using: [Embed(source='/assets/fonts/book/HogarthScrD-Regular.ttf', embedAsCFF="true"

Javascript Global Keyboard Handling, not hearing A-Z Keys?

瘦欲@ 提交于 2019-12-25 01:46:13
问题 I am trying to use Javascript to intercept keyboard events, so I can do CMD-W for "close-window" and whatnot, inside a Flash application, so the Browser doesn't get to use them. Well, I am able to listen for ALT, CTRL, and CMD onKeyDown/onKeyPress events, but I am not able to listen to anything else... Here is the code, in the index.html file from a Flex Project: <script language="JavaScript" type="text/javascript"> document.onkeydown = function(event) {applicationKeyboardHandler(event)}

DisplayObject snapshot in flex 3

此生再无相见时 提交于 2019-12-25 01:45:45
问题 i'm creating a visual editor in flex and need to let users export thier projects into Image format. But i have one problem: size of the canvas is fixed and when user add element which is out of these sizes some scroll bars added. And user continue working on the project. but when he want to take snapshot of the canvas he just get the visible part ot the canvas with scrollbars. how to get image of the fullsize canvas? The only solution i found is to check the positions and sizes of canvas

Flex: Why are TileList images disappearing on drag?

南楼画角 提交于 2019-12-25 01:44:52
问题 I'm developing a Flex Air (desktop) application that loads images from the local filesystem into a TileList. The user will then be able to drag (copy) these images out of the list onto another control. I've finally got the images showing up correctly (and not disappearing after scrolling the TileList) but they seem to disappear from the TileList at the start of a drag operation. I come from a .NET background and am just learning AS3/Flex, so if you see me using any anti-patterns here, feel

Changing tab border color at run time in flex

╄→尐↘猪︶ㄣ 提交于 2019-12-25 01:34:00
问题 How can I change border color of tab in tab navigator control at runtime? I am trying to access it with its id "mytab" and update it's style. this.mytab.setStyle("bordercolor","red"); A TabNavigator has multiple tabs and I have to change style of few tabs based on some logic. StyleDeclaration is applicable for all the tabs under tab navigoter but how can use CSSStyleDeclaration based on componentid? The only shortfall with this approach is that Style can not be changed for individual tab. 回答1

Connecting Flex to SQLite

北慕城南 提交于 2019-12-25 01:33:26
问题 In Flash builder, I'm struggling with basics of data retrieval from local database. Using Lita, I created a SQLite database with a single basic (item) table located in a "DAO" folder .It is meant to populate a List. and I have 2 problems: How to embed the database (with all its pre-populated data) without recreating it from scratch as shown in many tutorials ? For the purpose of prototyping, how to link the data retrieved a single MXML file directly in the list without creating many other

How do i store cookies in flex?

做~自己de王妃 提交于 2019-12-25 01:28:08
问题 I want to store some values in browser using cookies but i don't do i do ? please help me 回答1: You have two options. Using ExternalInterface and javascript. The ExternalInterface class is the External API, an application programming interface that enables straightforward communication between ActionScript and the Flash Player container– for example, an HTML page with JavaScript. Adobe recommends using ExternalInterface for all JavaScript-ActionScript communication. Using local SharedObjects