Flex :: Use 'bubbles' In Flex Events?
Feb 21, 2012I've doubt when we create custom event in flex.
Why do we use 'type:String, bubbles:Boolean=false, cancelable:Boolean=false' these parameter in flex events.
I've doubt when we create custom event in flex.
Why do we use 'type:String, bubbles:Boolean=false, cancelable:Boolean=false' these parameter in flex events.
I have an image that has call out bubbles in it (call out = comic book text bubbles - i didn't know they were called that). I need to find where each of these are in a given image and get the location and size of each of these.
AS3, Flex, Bitmap
I am using a custom component within another custom component in a flex mxml application file.Is it possible to bubble events from an inner component to the outer component and handle events in the outer component?
View 3 RepliesI have a scenario where I am listening to both CLICK and MouseDown events for an object.
On MouseDown I do a startDrag(). And on Click, I perform something else.
But the problem is that, MouseDown event fires first and it initiates a drag. The click event does not fire.
LinkeSetFx has its own CollectionEvent, but I don't know how to map the LinkedSetFx event to mx.events.collectionEvent(I want use it in ComboBox). LinkedSetFx is in AS3Commons-collection framework.Here is the url, choose the as3commons-collections-1.0.0.zip, you'll find LinkedSetFx in srcorgas3commonscollectionsfx
View 1 Repliespackage classes.events
{
import flash.events.Event;
public class ASSEvent extends Event
{
public static const ALERT:String = " Add Alert";
[Code]...
We have a Flex application which goes fullscreen on startup (which is possible when it's a projector .exe). When a user presses ESC, the application exits fullscreen mode. Is there any way to prevent this? This because we want to use the ESC-key for other functionality.Normally all keyboard input is disabled in fullscreen mode, but not when we run it as a projector. I already tried capturing the FullScreenEvent.FULL_SCREEN event without luck (this event is only fired when the user selects "Full Screen" in the Adobe Flash Player or hits "CTRL + F".
View 3 RepliesI am trying to display database details in a Flex datagrid and connected using HTTP Service. It was able to display details without any issue when I was working in the FlashBuilder 4.5, however, I deployed the bin-debug part in the Tomcat webserver to access it globally.
I am experiencing this error message when I am trying to access the swf file "HTTP request error Error: [IOErrorEvent type="ioError" bubbles=false cancelable=false eventPhase=2 text="Error #2032"]. URL: http://localhost:8084/UA/details.jsp"
I tried to create the crossdomain.xml file and deployed in the root directory but still experiencing the same error.Here is my crossdomain.xml :
<?xml version="1.0"?>
<!DOCTYPE cross-domain-policy SYSTEM "http://www.macromedia.com/xml/dtds/cross-domain-policy.dtd">
<cross-domain-policy>[code].....
i have following problem, when i create box in action script and whe i addEventListner for drop accept, and if i add this box to some parent box, then this event is not working, if i add this event to not child but to parent box, then it is working, what can i do if i want create many boxes, add to them events listners and then add them all to some other parent box?
View 1 Repliespackage com.services
{
import com.asfusion.mate.events.ResponseEvent;
import com.events.navigation.DesgManagementEvent
import flash.events.EventDispatcher;
import mx.controls.Alert;
[Code]...
I am able to get the result, but not able to dispatch the event from the custom actionScript class. I googled and got the riposte that you need to add it to display list.
I'm developing an AIR application with Flash Builder 4 Beta 2 (nightly SDK) an am not using a framework like mate. I have a couple of views and components in my application. An outline might look like this:
root
|- mainview
|-- toolbar
[code].....
I am adding a key listener to my AIR application like so:
<mx:WindowedApplication
xmlns:mx="http://www.adobe.com/2006/mxml"
keyDown="onKeyDown(event)">
Yet only sometimes when I press keys does it actually invoke. I have no clue why, I thought maybe something else has focus. Well I cannot add key listeners to NativeWindow or NativeApplication, and I would assume if it is on the WindowedApplication which is the root element, that as long as my application has focus the key presses should invoke the listener.
regarding the events related to menubar sub items, here is some code iam working with
[Code]...
i want to handle events wen particular subitem is clicked for example ,if submnu item hod of cse is clicked it should go to the particular mxml page ,and if hod of ece is clicked it shold goto other page how do i differentiate each page of particular deparment how do select that particulasr item of that particular submenu itm
I'm trying to capture key events in a mx:Image and I can't get it to work.
<?xml version="1.0" encoding="utf-8" ?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" />
<mx:Canvas width="100%" height="100%">
[code]....
When I press a key when the mouse is over the image I expect the label text to change to "Something", but nothing happens. I've done all sorts of combination of enabled and putting the keyDown on the canvas and the label as well.
I have a small flex application. What I want to achieve is, I want my user to pass the script as a parameter. so he has the flexibility to do anything with the buttons->like add event, hide the other buttons.
Something like this(below)
<param name="script" value="import flash.events.Event;
private function printMessage(event:Event):void {
message.text += event.target.label + " pressed" + "
";
}">
I'm doing some newbie tests, so I decided to capture the keyboard events to move a rectangle. But I don't get the desired result. Unless I click on the TextArea box, I'm not able to capture the event key code. After that, all goes pretty well.
[Code]...
I have a custom event class public class FFTDrawEvent extends Event {
public static const DRAW_EVENT:String = "drawEvent";
private var _param:Array = new Array();
public function FFTDrawEvent(type:String, __param:Array, bubbles:Boolean=true, cancelable:Boolean=false) {
_param = __param;
super(type, bubbles, cancelable);
[Code]...
Both class (Dispatcher & Listener) are Child class of a MXML application. Also listen to the event in the parent MXML application doens't work. Listen to the event in the dispatching class itself somehow works.
I have to feeling that the EventDispatcher class is not the right one to dispatch events to a mxml application or respectivly AS classes, which extend/inherent from a MXML component class.
I am having trouble wiring up an event listener to a fl.transitions.Transition.
Is it possible to somehow view all the events an object fires? That way I could check I am using the correct event (and possible view better ones to use).
I have a text area on which I would like to listen to change events when I change the text formatting using setFormatOfRange(). So far all other events I have tried, such as Event.CHANGE or TextOperationEvent.CHANGE are only dispatched when the actual text is changed.
Anyone know what I should be listening for ?
I have two separate advancedDataGrid instances (let's call them A and B). What I'd like to do: when clicking on grid A. I'd like:
for grid A to handle the click normally (i.e. default advancedDataGrid behavior)
for grid B to receive a click event a certain location and handle such event using advancedDataGrid default behavior (i.e. without having to write a handler for such click).
I've managed to dispatchEvent a MouseEvent.CLICK to grid B and to handle such event by creating an event listener, but really I'd like for grid B to handle the event on its own (i.e. without having to re-rewrite a handler), and that doesn't seem to be the case. Is MouseEvent.CLICK even the right event?
I have Flex 4 application in which I have one component as top layer which displays something like tooltips, basically user sees "presentation" which explains usage and meaning of the tools "below", sliders, checkboxes, text fields etc. I made this "presentation" using sequences so first tooltip is visible, then becomes invisible, second is visible etc.
I tried to disable mouseChildren, mouseEnabled and other possible parameters which would disable those tooltips from preventing user clicking on some button or checkbox. Obviously those components which render tooltips even tough invisible, are still "clickable".
I need to process this chain using one LoadXML method and one urlLoader object:
ResourceLoader.Instance.LoadXML("Config.xml"); ResourceLoader.Instance.LoadXML("GraphicsSet.xml");
Loader starts loading after first frameFunc iteration (why?) I want it to start immediatly.(optional)
And it starts loading only "GraphicsSet.xml"
[Code]...
I am working in Flex3. Here I have a datagrid which contains data. some columns are editable. when the user changes the column data web service is called. Here using function of focusOut, I am calling the web service by sending the data which comes from the datagrid through focusOut function. Now I want to call the web service when the user changes the column data and presses keyboard key 'Enter'. Here I can call function but the event does not carry datagrid's data to the function being called.
View 3 RepliesIs it possible to dispatch an event from a public static var in Flex? I'm doing this, and Flex throws me an error:
File board.mxml: public static var actionBar:ActionBar;
<mx:VBox>
<ActionBar:ActionBar id="actionBar"/>
</mx:VBox>
File layerMng.as:
board.actionBar.dispatchEvent(...)
Error -> 1119: Access of possibly undefined property actionBar through a reference with static type Class.
I'm trapping keyboard events on the stage and dispatching custom events through a framework (Mate, though I don't know that this is an important issue), but I'm pretty confused by the scope. The structure is:application (traps keyboard events and dispatches custom event mainPanel (receives dispatched events but mainCalendar (a child element) is null on debugging. Obviously if I try to call a public method on mainCalendar it errors out, even though it's a child of mainPanel. However, mainCalendar is NOT null IF I use FlexGlobals.topLevelApplication.mainPanel.mainCalendar. Outerdocument and parentDocument do not expose mainCalendar either, BTW mainCalendar (a custom component inside mainPanel with public methods. Creation policy is 'all' and it's visible and exists long before I trap any keystrokes at the top level)Could someone take a minute and explain why the mainCalendar is out of scope when mainPanel receives a custom event, even though mainCalendar is a child of mainPanel. Is there a better way to manage the events so I don't have to always address the component via the topLevelApplication?
View 1 RepliesI am looking for a simple timeline chart, that I can display several events on over a varying timespan. I haven't found any specific charts in Flex, has anybody created or used anything along these lines? [URL]
View 2 RepliesIn ACE Flex 3 , there is a topic "Handle Framework Events". Any document which lists all the 'required' framework events for ACE test? So I could know what are "framework" events and will focus on them.
View 1 RepliesI have written a custom component for drawing a circle in Flex. But When I try to write a click event or mouseDown event for that component, it doesn't work.[code]...
The "Hello" Alert is displayed only at a particular point and guess is, at the point, (175,150) the x, y co-ordinates of the circle. But shouldn't it be displayed wherever I click on the MyCircle component?? how to enable it in that way?
Also the mouseDown function doesn't work for MyCircle,but if have the event for the VBox, the Alerts are displayed.
I am writing an AIR application in Flex. The application needs to be able to handle shortcuts on both Mac and Windows. I have the shortcuts on the Windows side working, but the same application on a Mac doesnt seem to trigger the commandKey property on a Keyboard event when the user is also using another key in combination (ex. command+g doesnt work)
View 2 RepliesI would like to track the customer experience in downloading and initializing my flex app.
(a) Is there a way to pass data from preloader to the application? I would like to pass the time it takes to download and the time it takes to initialize.
(b)Alternatively: Is there an event at the application level that corresponds to the preloader events:
1. Download complete
2. Initialization complete (same as Application creationComplete)