/* Copyright (c) 2009 Yahoo! Inc. All rights reserved. The copyrights embodied in the content of this file are licensed under the BSD (revised) open source license */ package com.yahoo.astra.fl.events { import fl.controls.listClasses.ICellRenderer; import flash.events.Event; /** * For events that are associated with activities * in tree, such as when a tree branch opens or closes. * */ public class TreeEvent extends Event { //-------------------------------------------------------------------------- // // Class constants // //-------------------------------------------------------------------------- /** * The TreeEvent.ITEM_CLOSE event type constant indicates that a tree * branch closed or collapsed. * *
The properties of the event object for this event type have the * following values. * Not all properties are meaningful for all kinds of events. * See the detailed property descriptions for more information.
* *Property | Value |
---|---|
itemRenderer |
* The ListItemRenderer for the node that closed |
bubbles | false |
cancelable | false |
currentTarget | The Object that defines the
* event listener that handles the event. For example, if you use
* myButton.addEventListener() to register an event listener,
* myButton is the value of the currentTarget . |
triggerEvent |
* If the node closed in response to a user action, * identifies it as a keyboard action or a mouse action. |
item | the Tree item (node) that closed |
target | The Object that dispatched the event;
* it is not always the Object listening for the event.
* Use the currentTarget property to always access the
* Object listening for the event. |
type | TreeEvent.ITEM_CLOSE |
The properties of the event object for this event type have the * following values. * Not all properties are meaningful for all kinds of events. * See the detailed property descriptions for more information.
* *Property | Value |
---|---|
itemRenderer |
* The ListItemRenderer for the item (node) that opened |
bubbles | false |
cancelable | false |
currentTarget | The Object that defines the
* event listener that handles the event. For example, if you use
* myButton.addEventListener() to register an event listener,
* myButton is the value of the currentTarget . |
triggerEvent |
* If the item (node) opened in response to a user action, * identifies it as a keyboard action or a mouse action. |
item | the Tree node that opened. |
target | The Object that dispatched the event;
* it is not always the Object listening for the event.
* Use the currentTarget property to always access the
* Object listening for the event. |
type | TreeEvent.ITEM_OPEN |
null
if this event was triggered programatically.
*/
public var triggerEvent:Event;
//--------------------------------------------------------------------------
//
// Overridden methods: Event
//
//--------------------------------------------------------------------------
/**
* @private
*/
override public function clone():Event
{
return new TreeEvent(type, bubbles, cancelable,
item, itemRenderer, triggerEvent);
}
}
}