Project: Adobe Flex SDK
Revision: 3101
Author: mhorn@adobe.com
Date: 04 Sep 2008 14:54:28
Changes:Marshall Plan ASDoc updates
Files:modified: /flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/events/EventListenerRequest.as (
try)
modified: /flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/utils/SecurityUtil.as (
try)
modified: /flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/core/ISWFLoader.as (
try)
modified: /flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/events/InvalidateRequestData.as (
try)
modified: /flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/core/ISWFBridgeProvider.as (
try)
modified: /flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/controls/SWFLoader.as (
try)
modified: /flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/events/InterManagerRequest.as (
try)
modified: /flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/core/ISWFBridgeGroup.as (
try)
modified: /flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/events/SandboxMouseEvent.as (
try)
modified: /flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/events/InterDragManagerEvent.as (
try)
modified: /flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/core/SWFBridgeGroup.as (
try)
modified: /flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/events/SWFBridgeEvent.as (
try)
Diff:
| ... | ...@@ -15,14 +15,14 @@ |
| 15 | 15 | import flash.events.Event;
|
| 16 | 16 |
|
| 17 | 17 | /**
|
| 18 | | * Request sent from a systemManager to a systemManager in another
|
| 19 | | * SWF via their bridge to add or remove a listener to a specified event
|
| 20 | | * on your behalf. The data property is not used. Only certain events
|
| 21 | | * can be requested. When the event is triggered in the other SWF, that
|
| 18 | * Request sent from one SystemManager to a SystemManager in another
|
| 19 | * application through their bridge to add or remove a listener to a specified event
|
| 20 | * on your behalf. The <code>data</code> property is not used. Only certain events
|
| 21 | * can be requested. When the event is triggered in the other application, that
|
| 22 | 22 | * event is re-dispatched through the bridge where the requesting
|
| 23 | | * systemManager picks up the event and redispatches it from itself.
|
| 23 | * SystemManager picks up the event and redispatches it from itself.
|
| 24 | 24 | * In general, this request is generated because some other code called
|
| 25 | | * addEventListener for one of the approved events on its systemManager.
|
| 25 | * the <code>addEventListener()</code> method for one of the approved events on its SystemManager.
|
| 26 | 26 | */
|
| 27 | 27 | public class EventListenerRequest extends SWFBridgeRequest
|
| 28 | 28 | {
|
| ... | ...@@ -53,7 +53,11 @@ |
| 53 | 53 |
|
| 54 | 54 | /**
|
| 55 | 55 | * Marshals an event by copying the relevant parameters
|
| 56 | | * from the event into a new event
|
| 56 | * from the event into a new event.
|
| 57 | *
|
| 58 | * @param event The event to marshal.
|
| 59 | *
|
| 60 | * @return An EventListenerRequest that defines the new event.
|
| 57 | 61 | */
|
| 58 | 62 | public static function marshal(event:Event):EventListenerRequest
|
| 59 | 63 | {
|
| ... | ...@@ -74,20 +78,22 @@ |
| 74 | 78 | /**
|
| 75 | 79 | * Creates a new request to add or remove an event listener.
|
| 76 | 80 | *
|
| 77 | | * @param type EventListenerRequest.ADD or EventListenerRequest.REMOVE
|
| 78 | | *
|
| 79 | | * @param bubbles Specifies whether the event can bubble up the display list hierarchy.
|
| 80 | | *
|
| 81 | | * @param cancelable Specifies whether the behavior associated with the event can be prevented.
|
| 82 | | *
|
| 83 | | * @param eventType type of message you would normally pass to
|
| 84 | | * addEventListener.
|
| 85 | | *
|
| 86 | | * @param useCapture See addEventListener.
|
| 87 | | *
|
| 88 | | * @param priority See addEventListener.
|
| 89 | | *
|
| 90 | | * @param useWeakReference See addEventListener.
|
| 81 | * @param type The event type; indicates the action that caused the event. Either <code>EventListenerRequest.ADD</code>
|
| 82 | * or <code>EventListenerRequest.REMOVE</code>.
|
| 83 | *
|
| 84 | * @param bubbles Specifies whether the event can bubble up the display list hierarchy.
|
| 85 | *
|
| 86 | * @param cancelable Specifies whether the behavior associated with the event can be prevented.
|
| 87 | *
|
| 88 | * @param eventType The type of message you would normally pass to the <code>addEventListener()</code> method.
|
| 89 | *
|
| 90 | * @param useCapture Determines whether the listener works in the capture phase or the target and bubbling phases.
|
| 91 | *
|
| 92 | * @param priority The priority level of the event listener. Priorities are designated by a 32-bit integer.
|
| 93 | *
|
| 94 | * @param useWeakReference Determines whether the reference to the listener is strong or weak.
|
| 95 | *
|
| 96 | * @see flash.events.IEventDispatcher#addEventListener
|
| 91 | 97 | */
|
| 92 | 98 | public function EventListenerRequest(type:String, bubbles:Boolean = false,
|
| 93 | 99 | cancelable:Boolean = true,
|
| ... | ...@@ -17,7 +17,7 @@ |
| 17 | 17 | import mx.core.ISWFBridgeProvider; |
| 18 | 18 | |
| 19 | 19 | /** |
| 20 | | * Utilities for working with security issues. |
| 20 | * Utilities for working with security-related issues. |
| 21 | 21 | */ |
| 22 | 22 | public class SecurityUtil |
| 23 | 23 | { |
| ... | ...@@ -30,7 +30,11 @@ |
| 30 | 30 | //-------------------------------------------------------------------------- |
| 31 | 31 | |
| 32 | 32 | /** |
| 33 | | * Tests if there is mutual trust between a SystemManager and its parent. |
| 33 | * Tests if there is mutual trust between the parent and child of the specified bridge. |
| 34 | * |
| 35 | * @param bp The provider of the bridge that connects the two applications. |
| 36 | * |
| 37 | * @return <code>true</code> if there is mutual trust; otherwise <code>false</code>. |
| 34 | 38 | */ |
| 35 | 39 | public static function hasMutualTrustBetweenParentAndChild(bp:ISWFBridgeProvider):Boolean |
| 36 | 40 | { |
| ... | ...@@ -32,12 +32,12 @@ |
| 32 | 32 | //---------------------------------- |
| 33 | 33 | |
| 34 | 34 | /** |
| 35 | | * A flag that indictes whether the content is loaded so it can |
| 36 | | * interop with applications built with a different verion of Flex. |
| 35 | * A flag that indicates whether the content is loaded so that it can |
| 36 | * interoperate with applications that were built with a different verion of Flex. |
| 37 | 37 | * Compatibility with other Flex Applications is accomplished by loading |
| 38 | | * the application into a sibling ApplicationDomain. |
| 39 | | * This flag is not respected if the content needs to be loaded into differnt |
| 40 | | * SecurityDomain. |
| 38 | * the application into a sibling (or peer) ApplicationDomain. |
| 39 | * This flag is ignored if the sub application is loaded into a different |
| 40 | * SecurityDomain than the main application. |
| 41 | 41 | * If <code>true</code>, the content loads into a sibling ApplicationDomain. |
| 42 | 42 | * If <code>false</code>, the content loaded into a child ApplicationDomain. |
| 43 | 43 | * |
| ... | ...@@ -54,14 +54,14 @@ |
| 54 | 54 | * Get the bounds of the loaded application that are visible to the user |
| 55 | 55 | * on the screen. |
| 56 | 56 | * |
| 57 | | * @param allApplications Control if the visible rect is calculated based only on the |
| 57 | * @param allApplications Determine if the visible rectangle is calculated based only on the |
| 58 | 58 | * display objects in this application or all parent applications as well. |
| 59 | | * Including more parent applications may reduce the visible area returned. |
| 60 | | * If <code>true</code> then all applications are used to find the visible |
| 59 | * Including more parent applications might reduce the visible area returned. |
| 60 | * If <code>true</code>, then all applications are used to find the visible |
| 61 | 61 | * area, otherwise only the display objects in this application are used. |
| 62 | 62 | * |
| 63 | | * @return a <code>Rectangle</code> including the visible portion of the this |
| 64 | | * object. The rectangle is in global coordinates. |
| 63 | * @return A <code>Rectangle</code> that includes the visible portion of this |
| 64 | * object. The rectangle uses global coordinates. |
| 65 | 65 | */ |
| 66 | 66 | function getVisibleApplicationRect(allApplications:Boolean=false):Rectangle; |
| 67 | 67 | |
| ... | ...@@ -13,7 +13,7 @@ |
| 13 | 13 | /**
|
| 14 | 14 | * The InvalidateRequestData class defines constants for the values
|
| 15 | 15 | * of the <code>data</code> property of a SWFBridgeRequest object when
|
| 16 | | *
|
| 16 | * used with the <code>SWFBridgeRequest.INVALIDATE_REQUEST</code> request.
|
| 17 | 17 | */
|
| 18 | 18 | public final class InvalidateRequestData
|
| 19 | 19 | {
|
| ... | ...@@ -16,11 +16,11 @@ |
| 16 | 16 | |
| 17 | 17 | /** |
| 18 | 18 | * An implementor of ISWFProvider provides a bridge |
| 19 | | * to an application in a different sandbox |
| 19 | * to an application in a different security sandbox |
| 20 | 20 | * or to an application that was compiled with a different version |
| 21 | | * of Flex and is running in a separate ApplicationDomain. |
| 22 | | * This interface allows a caller to get a bridge to that application. |
| 23 | | * Once the caller has the bridge it can then dispatch events |
| 21 | * of the Flex compiler and is running in a separate ApplicationDomain. |
| 22 | * This interface lets a caller get a bridge to that application. |
| 23 | * Once the caller has the bridge, it can then dispatch events |
| 24 | 24 | * to the application. |
| 25 | 25 | */ |
| 26 | 26 | public interface ISWFBridgeProvider |
| ... | ...@@ -36,25 +36,25 @@ |
| 36 | 36 | //---------------------------------- |
| 37 | 37 | |
| 38 | 38 | /** |
| 39 | | * A bridge to the application associated with the implementor of this |
| 39 | * A bridge to the application that is associated with the implementor of this |
| 40 | 40 | * interface. The IEventDispatcher that can be used to send events to an |
| 41 | 41 | * application in a different ApplicationDomain or a different sandbox. |
| 42 | 42 | */ |
| 43 | 43 | function get swfBridge():IEventDispatcher; |
| 44 | 44 | |
| 45 | 45 | /** |
| 46 | | * Test if the child allows its parent to access its display objects or listen |
| 46 | * Tests if the child allows its parent to access its display objects or listen |
| 47 | 47 | * to messages that originate in the child. |
| 48 | 48 | * |
| 49 | | * <code>true</code> if access if allowed, false otherwise. |
| 49 | * <code>true</code> if access if allowed; otherwise <code>false</code>. |
| 50 | 50 | */ |
| 51 | 51 | function get childAllowsParent():Boolean; |
| 52 | 52 | |
| 53 | 53 | /** |
| 54 | | * Test if the parent allows its child to access its display objects or listen |
| 54 | * Tests if the parent allows its child to access its display objects or listen |
| 55 | 55 | * to messages that originate in the parent. |
| 56 | 56 | * |
| 57 | | * <code>true</code> if access if allowed, false otherwise. |
| 57 | * <code>true</code> if access if allowed; otherwise <code>false</code>. |
| 58 | 58 | */ |
| 59 | 59 | function get parentAllowsChild():Boolean; |
| 60 | 60 | } |
| ... | ...@@ -262,7 +262,7 @@ |
| 262 | 262 | * <mx:SWFLoader |
| 263 | 263 | * <strong>Properties</strong> |
| 264 | 264 | * autoLoad="true|false" |
| 265 | | * loadForCompatibility="true|false" |
| 265 | * loadForCompatibility="false|true" |
| 266 | 266 | * loaderContext="null" |
| 267 | 267 | * maintainAspectRatio="true|false" |
| 268 | 268 | * scaleContent="true|false" |
| ... | ...@@ -482,11 +482,11 @@ |
| 482 | 482 | [Inspectable(defaultValue="false")] |
| 483 | 483 | |
| 484 | 484 | /** |
| 485 | | * A flag that indictes whether the content is loaded so it can |
| 486 | | * interop with applications built with a different verion of Flex. |
| 487 | | * Compatibility with other Flex Applications is accomplished by loading |
| 488 | | * the application into a sibling ApplicationDomain. |
| 489 | | * This flag is not respected if the content needs to be loaded into differnt |
| 485 | * A flag that indicates whether the content is loaded so that it can |
| 486 | * interoperate with applications built with a different verion of the Flex compiler. |
| 487 | * Compatibility with other Flex applications is accomplished by loading |
| 488 | * the application into a sibling (or peer) ApplicationDomain. |
| 489 | * This flag is ignored if the content must be loaded into a different |
| 490 | 490 | * SecurityDomain. |
| 491 | 491 | * If <code>true</code>, the content loads into a sibling ApplicationDomain. |
| 492 | 492 | * If <code>false</code>, the content loaded into a child ApplicationDomain. |
| ... | ...@@ -1095,7 +1095,7 @@ |
| 1095 | 1095 | //-------------------------------------------------------------------------- |
| 1096 | 1096 | |
| 1097 | 1097 | /** |
| 1098 | | * @inheritdoc |
| 1098 | * @inheritDoc |
| 1099 | 1099 | */ |
| 1100 | 1100 | public function get swfBridge():IEventDispatcher |
| 1101 | 1101 | { |
| ... | ...@@ -1103,7 +1103,7 @@ |
| 1103 | 1103 | } |
| 1104 | 1104 | |
| 1105 | 1105 | /** |
| 1106 | | * @inheritdoc |
| 1106 | * @inheritDoc |
| 1107 | 1107 | */ |
| 1108 | 1108 | public function get childAllowsParent():Boolean |
| 1109 | 1109 | { |
| ... | ...@@ -1117,7 +1117,7 @@ |
| 1117 | 1117 | } |
| 1118 | 1118 | |
| 1119 | 1119 | /** |
| 1120 | | * @inheritdoc |
| 1120 | * @inheritDoc |
| 1121 | 1121 | */ |
| 1122 | 1122 | public function get parentAllowsChild():Boolean |
| 1123 | 1123 | { |
| ... | ...@@ -1366,7 +1366,7 @@ |
| 1366 | 1366 | //-------------------------------------------------------------------------- |
| 1367 | 1367 | |
| 1368 | 1368 | /** |
| 1369 | | * @inheritdoc |
| 1369 | * @inheritDoc |
| 1370 | 1370 | */ |
| 1371 | 1371 | public function getVisibleApplicationRect(allApplications:Boolean=false):Rectangle |
| 1372 | 1372 | { |
| ... | ...@@ -15,7 +15,7 @@ |
| 15 | 15 | import flash.events.Event;
|
| 16 | 16 |
|
| 17 | 17 | /**
|
| 18 | | * This is an event sent between application domains
|
| 18 | * This is an event that is sent between ApplicationDomains
|
| 19 | 19 | * to notify trusted listeners about activity in a particular manager.
|
| 20 | 20 | */
|
| 21 | 21 | public class InterManagerRequest extends Event
|
| ... | ...@@ -29,39 +29,39 @@ |
| 29 | 29 | //--------------------------------------------------------------------------
|
| 30 | 30 |
|
| 31 | 31 | /**
|
| 32 | | * Communication between CursorManagers use this request type
|
| 33 | | * The name property is the name of some CursorManager property
|
| 34 | | * The value property is value of that property
|
| 32 | * Communication between CursorManagers use this request type.
|
| 33 | * The <code>name</code> property is the name of some CursorManager property.
|
| 34 | * The <code>value</code> property is the value of that property.
|
| 35 | 35 | */
|
| 36 | 36 | public static const CURSOR_MANAGER_REQUEST:String = "cursorManagerRequest";
|
| 37 | 37 |
|
| 38 | 38 | /**
|
| 39 | | * Communication between DragManagers use this request type
|
| 40 | | * The name property is the name of some DragManager property
|
| 41 | | * The value property is value of that property
|
| 39 | * Communication between DragManagers use this request type.
|
| 40 | * The <code>name</code> property is the name of some DragManager property.
|
| 41 | * The <code>value</code> property is the value of that property.
|
| 42 | 42 | */
|
| 43 | 43 | public static const DRAG_MANAGER_REQUEST:String = "dragManagerRequest";
|
| 44 | 44 |
|
| 45 | 45 | /**
|
| 46 | 46 | * Ask the other ApplicationDomain to instantiate a manager in
|
| 47 | | * that ApplicationDomain (if it isn't already instantiated)
|
| 47 | * that ApplicationDomain (if it is not already instantiated)
|
| 48 | 48 | * so it is available to listen to subsequent
|
| 49 | 49 | * InterManagerRequests.
|
| 50 | | * The name property is the name of the manager to instantiate.
|
| 50 | * The <code>name</code> property is the name of the manager to instantiate.
|
| 51 | 51 | */
|
| 52 | 52 | public static const INIT_MANAGER_REQUEST:String = "initManagerRequest";
|
| 53 | 53 |
|
| 54 | 54 | /**
|
| 55 | | * Request the SystemManager to perform some action
|
| 56 | | * The name property is the name of action to perform
|
| 57 | | * The value property is values needed to perform that action
|
| 55 | * Request the SystemManager to perform some action.
|
| 56 | * The <code>name</code> property is the name of action to perform.
|
| 57 | * The <code>value</code> property is the value needed to perform that action.
|
| 58 | 58 | */
|
| 59 | 59 | public static const SYSTEM_MANAGER_REQUEST:String = "systemManagerRequest";
|
| 60 | 60 |
|
| 61 | 61 | /**
|
| 62 | | * Communication between ToolTipManagers use this request type
|
| 63 | | * The name property is the name of some ToolTipManager property
|
| 64 | | * The value property is value of that property
|
| 62 | * Communication between ToolTipManagers use this request type.
|
| 63 | * The <code>name</code> property is the name of some ToolTipManager property.
|
| 64 | * The <code>value</code> property is the value of that property.
|
| 65 | 65 | */
|
| 66 | 66 | public static const TOOLTIP_MANAGER_REQUEST:String = "tooltipManagerRequest";
|
| 67 | 67 |
|
| ... | ...@@ -72,15 +72,19 @@ |
| 72 | 72 | //--------------------------------------------------------------------------
|
| 73 | 73 |
|
| 74 | 74 | /**
|
| 75 | | * Constructor.
|
| 75 | * Constructor. Does not return anything, but the <code>value</code> property can be modified
|
| 76 | * to represent a return value of a method.
|
| 76 | 77 | *
|
| 77 | | * @param name Name of property or method or name of manager to instantiate
|
| 78 | | *
|
| 79 | | * @param value Value of property, or array of parameters
|
| 80 | | * for method (if not-null).
|
| 78 | * @param type The event type; indicates the action that caused the event.
|
| 81 | 79 | *
|
| 82 | | * @return None, but the value property can be modified
|
| 83 | | * to represent a return value of a method.
|
| 80 | * @param bubbles Specifies whether the event can bubble up the display list hierarchy.
|
| 81 | *
|
| 82 | * @param cancelable Specifies whether the behavior associated with the event can be prevented.
|
| 83 | *
|
| 84 | * @param name Name of a property or method or name of a manager to instantiate.
|
| 85 | *
|
| 86 | * @param value Value of a property, or an array of parameters
|
| 87 | * for a method (if not null).
|
| 84 | 88 | */
|
| 85 | 89 | public function InterManagerRequest(type:String, bubbles:Boolean = false,
|
| 86 | 90 | cancelable:Boolean = false,
|
| ... | ...@@ -103,7 +107,7 @@ |
| 103 | 107 | //----------------------------------
|
| 104 | 108 |
|
| 105 | 109 | /**
|
| 106 | | * Name of property or method or manager to instantiate
|
| 110 | * Name of property or method or manager to instantiate.
|
| 107 | 111 | */
|
| 108 | 112 | public var name:String;
|
| 109 | 113 |
|
| ... | ...@@ -17,8 +17,8 @@ |
| 17 | 17 | |
| 18 | 18 | /** |
| 19 | 19 | * A sandbox bridge group is a group of bridges that represent |
| 20 | | * applications this application may communicate with. |
| 21 | | * This application may not share memory with, or may not have access to, |
| 20 | * applications that this application can communicate with. |
| 21 | * This application can not share memory with, or can not have access to, |
| 22 | 22 | * the other applications in the group, but uses the bridge |
| 23 | 23 | * to communicate with these applications. |
| 24 | 24 | */ |
| ... | ...@@ -56,13 +56,13 @@ |
| 56 | 56 | * |
| 57 | 57 | * @param bridge The bridge to communicate with the child content. |
| 58 | 58 | * |
| 59 | | * @param bridgeProvider The display object that loaded the content |
| 60 | | * represented by the bridge. Usually this is will an instance of SWFLoader. |
| 59 | * @param bridgeProvider The DisplayObject that loaded the content |
| 60 | * represented by the bridge. Usually this is will be an instance of the SWFLoader class. |
| 61 | 61 | */ |
| 62 | 62 | function addChildBridge(bridge:IEventDispatcher, bridgeProvider:ISWFBridgeProvider):void; |
| 63 | 63 | |
| 64 | 64 | /** |
| 65 | | * Removes the child bridge. |
| 65 | * Removes The child bridge. |
| 66 | 66 | * |
| 67 | 67 | * @param bridge The bridge to remove. |
| 68 | 68 | */ |
| ... | ...@@ -75,7 +75,7 @@ |
| 75 | 75 | * and the <code>event.target</code> is the bridge. |
| 76 | 76 | * The bridge can then be converted into the owning DisplayObject. |
| 77 | 77 | * |
| 78 | | * @param bridge Documentation is not currently available. |
| 78 | * @param bridge The target bridge. |
| 79 | 79 | * |
| 80 | 80 | * @return The object that loaded the child. |
| 81 | 81 | */ |
| ... | ...@@ -85,15 +85,14 @@ |
| 85 | 85 | * Gets all of the child bridges in this group. |
| 86 | 86 | * |
| 87 | 87 | * @return An array of all the child bridges in this group. |
| 88 | | * Each object in the array is of type <code>IEventDispatcher</code> |
| 88 | * Each object in the array is of type <code>IEventDispatcher</code>. |
| 89 | 89 | */ |
| 90 | 90 | function getChildBridges():Array /* of IEventDispatcher */; |
| 91 | 91 | |
| 92 | 92 | /** |
| 93 | 93 | * Tests if the given bridge is one of the sandbox bridges in this group. |
| 94 | 94 | * |
| 95 | | * @return <code>true</code> if the handle is found, |
| 96 | | * and <code>false</code> otherwise. |
| 95 | * @return <code>true</code> if the handle is found; otherwise <code>false</code>. |
| 97 | 96 | */ |
| 98 | 97 | function containsBridge(bridge:IEventDispatcher):Boolean; |
| 99 | 98 | } |
| ... | ...@@ -15,8 +15,8 @@ |
| 15 | 15 | import flash.events.Event;
|
| 16 | 16 |
|
| 17 | 17 | /**
|
| 18 | | * This is an event sent between sandboxes to notify listeners
|
| 19 | | * about mouse activity in another sandbox.
|
| 18 | * This is an event sent between applications in different security sandboxes to notify listeners
|
| 19 | * about mouse activity in another security sandbox.
|
| 20 | 20 | *
|
| 21 | 21 | * For security reasons, some fields of a MouseEvent are not sent
|
| 22 | 22 | * in a SandboxMouseEvent.
|
| ... | ...@@ -67,8 +67,13 @@ |
| 67 | 67 | //
|
| 68 | 68 | //--------------------------------------------------------------------------
|
| 69 | 69 |
|
| 70 | | /**
|
| 71 | | * Documentation is not currently available.
|
| 70 | /**
|
| 71 | * Marshal a SWFBridgeRequest from a remote ApplicationDomain into the current
|
| 72 | * ApplicationDomain.
|
| 73 | *
|
| 74 | * @param event A SWFBridgeRequest that might have been created in a different ApplicationDomain.
|
| 75 | *
|
| 76 | * @return A SandboxMouseEvent created in the caller's ApplicationDomain.
|
| 72 | 77 | */
|
| 73 | 78 | public static function marshal(event:Event):SandboxMouseEvent
|
| 74 | 79 | {
|
| ... | ...@@ -88,6 +93,21 @@ |
| 88 | 93 |
|
| 89 | 94 | /**
|
| 90 | 95 | * Constructor.
|
| 96 | *
|
| 97 | * @param type The event type; indicates the action that caused the event.
|
| 98 | *
|
| 99 | * @param bubbles Specifies whether the event can bubble up the display list hierarchy.
|
| 100 | *
|
| 101 | * @param cancelable Specifies whether the behavior associated with the event can be prevented.
|
| 102 | *
|
| 103 | * @param ctrlKey Indicates whether the <code>Ctrl</code> key was pressed.
|
| 104 | *
|
| 105 | * @param altKey Indicates whether the <code>Alt</code> key was pressed.
|
| 106 | *
|
| 107 | * @param shiftKey Indicates whether the <code>Shift</code> key was pressed.
|
| 108 | *
|
| 109 | * @param buttonDown Indicates whether the primary mouse button is pressed (true) or not (false).
|
| 110 | *
|
| 91 | 111 | */
|
| 92 | 112 | public function SandboxMouseEvent(type:String, bubbles:Boolean = false,
|
| 93 | 113 | cancelable:Boolean = false,
|
| ... | ...@@ -115,6 +135,8 @@ |
| 115 | 135 | //----------------------------------
|
| 116 | 136 |
|
| 117 | 137 | /**
|
| 138 | * Indicates whether the <code>Alt</code> key was pressed.
|
| 139 | *
|
| 118 | 140 | * @see flash.events.MouseEvent#altkey
|
| 119 | 141 | */
|
| 120 | 142 | public var altKey:Boolean;
|
| ... | ...@@ -124,6 +146,8 @@ |
| 124 | 146 | //----------------------------------
|
| 125 | 147 |
|
| 126 | 148 | /**
|
| 149 | * Indicates whether the primary mouse button is pressed (true) or not (false).
|
| 150 | *
|
| 127 | 151 | * @see flash.events.MouseEvent#buttonDown
|
| 128 | 152 | */
|
| 129 | 153 | public var buttonDown:Boolean;
|
| ... | ...@@ -133,6 +157,8 @@ |
| 133 | 157 | //----------------------------------
|
| 134 | 158 |
|
| 135 | 159 | /**
|
| 160 | * Indicates whether the <code>Ctrl</code> key was pressed.
|
| 161 | *
|
| 136 | 162 | * @see flash.events.MouseEvent#ctrlKey
|
| 137 | 163 | */
|
| 138 | 164 | public var ctrlKey:Boolean;
|
| ... | ...@@ -142,6 +168,8 @@ |
| 142 | 168 | //----------------------------------
|
| 143 | 169 |
|
| 144 | 170 | /**
|
| 171 | * Indicates whether the <code>Shift</code> key was pressed.
|
| 172 | *
|
| 145 | 173 | * @see flash.events.MouseEvent#shiftKey
|
| 146 | 174 | */
|
| 147 | 175 | public var shiftKey:Boolean;
|
| ... | ...@@ -20,18 +20,18 @@ |
| 20 | 20 | import mx.events.DragEvent;
|
| 21 | 21 |
|
| 22 | 22 | /**
|
| 23 | | * This is an event sent between DragManagers
|
| 24 | | * in separate ApplicationDomains that are trusted to
|
| 23 | * An event sent between DragManagers that are
|
| 24 | * in separate but trusted ApplicationDomains to
|
| 25 | 25 | * handle the dispatching of DragEvents to the drag targets.
|
| 26 | | * One DragManager has a DragProxy that is moving with
|
| 27 | | * the mouse and looking for changes to the dropTarget.
|
| 28 | | * It can't directly dispatch the DragEvent to a potential
|
| 26 | * One DragManager has a DragProxy that moves with
|
| 27 | * the mouse and looks for changes to the dropTarget.
|
| 28 | * It cannot directly dispatch the DragEvent to a potential
|
| 29 | 29 | * target in another ApplicationDomain because code
|
| 30 | 30 | * in that ApplicationDomain would not type-match on DragEvent.
|
| 31 | 31 | * Instead, the DragManager dispatches a InterDragManagerEvent
|
| 32 | | * that the other ApplicationDomain's DragManager is listening
|
| 32 | * that the other ApplicationDomain's DragManager listens
|
| 33 | 33 | * for and it marshals the DragEvent and dispatches it to
|
| 34 | | * the potential dropTarget
|
| 34 | * the potential dropTarget.
|
| 35 | 35 | */
|
| 36 | 36 | public class InterDragManagerEvent extends DragEvent
|
| 37 | 37 | {
|
| ... | ...@@ -46,7 +46,7 @@ |
| 46 | 46 | /**
|
| 47 | 47 | * Dispatch a DragEvent event to a target in another ApplicationDomain.
|
| 48 | 48 | * The receiving DragManager marshals the DragEvent and dispatches it
|
| 49 | | * to the target specified in the dropTarget property
|
| 49 | * to the target specified in the <code>dropTarget</code> property.
|
| 50 | 50 | *
|
| 51 | 51 | */
|
| 52 | 52 | public static const DISPATCH_DRAG_EVENT:String =
|
| ... | ...@@ -61,6 +61,42 @@ |
| 61 | 61 |
|
| 62 | 62 | /**
|
| 63 | 63 | * Constructor.
|
| 64 | *
|
| 65 | * @param type The event type; indicates the action that caused the event.
|
| 66 | *
|
| 67 | * @param bubbles Specifies whether the event can bubble up the display list hierarchy.
|
| 68 | *
|
| 69 | * @param cancelable Specifies whether the behavior associated with the event can be prevented.
|
| 70 | *
|
| 71 | * @param localX The horizontal coordinate at which the event occurred relative to the containing sprite.
|
| 72 | *
|
| 73 | * @param localY The vertical coordinate at which the event occurred relative to the containing sprite.
|
| 74 | *
|
| 75 | * @param relatedObject A reference to a display list object that is related to the event.
|
| 76 | *
|
| 77 | * @param ctrlKey Indicates whether the <code>Ctrl</code> key was pressed.
|
| 78 | *
|
| 79 | * @param altKey Indicates whether the <code>Alt</code> key was pressed.
|
| 80 | *
|
| 81 | * @param shiftKey Indicates whether the <code>Shift</code> key was pressed.
|
| 82 | *
|
| 83 | * @param buttonDown Indicates whether the primary mouse button is pressed (true) or not (false).
|
| 84 | *
|
| 85 | * @param delta Indicates how many lines should be scrolled for each unit the user rotates the mouse wheel.
|
| 86 | *
|
| 87 | * @param dropTarget The potential drop target in the other application domain (which is why it is a DisplayObject and not some other class).
|
| 88 | *
|
| 89 | * @param dragEventType The event type for the DragEvent to be used by the receiving DragManager when creating the marshaled DragEvent.
|
| 90 | *
|
| 91 | * @param dragInitiator IUIComponent that specifies the component initiating
|
| 92 | * the drag.
|
| 93 | *
|
| 94 | * @param dragSource A DragSource object containing the data being dragged.
|
| 95 | *
|
| 96 | * @param action The specified drop action, such as <code>DragManager.MOVE</code>.
|
| 97 | *
|
| 98 | * @param draggedItem An object representing the item that was dragged.
|
| 99 | *
|
| 64 | 100 | */
|
| 65 | 101 | public function InterDragManagerEvent(type:String, bubbles:Boolean = false,
|
| 66 | 102 | cancelable:Boolean = false,
|
| ... | ...@@ -106,7 +142,7 @@ |
| 106 | 142 | //----------------------------------
|
| 107 | 143 |
|
| 108 | 144 | /**
|
| 109 | | * The potential drop target in the other application domain
|
| 145 | * The potential drop target in the other ApplicationDomain
|
| 110 | 146 | * (which is why it is a DisplayObject and not some other class).
|
| 111 | 147 | */
|
| 112 | 148 | public var dropTarget:DisplayObject;
|
| ... | ...@@ -119,6 +155,7 @@ |
| 119 | 155 | * The event type for the DragEvent to be used
|
| 120 | 156 | * by the receiving DragManager when creating the
|
| 121 | 157 | * marshaled DragEvent.
|
| 158 | *
|
| 122 | 159 | * @see mx.events.DragEvent
|
| 123 | 160 | */
|
| 124 | 161 | public var dragEventType:String;
|
| ... | ...@@ -109,7 +109,7 @@ |
| 109 | 109 | //-------------------------------------------------------------------------- |
| 110 | 110 | |
| 111 | 111 | /** |
| 112 | | * @inheritdoc |
| 112 | * @inheritDoc |
| 113 | 113 | */ |
| 114 | 114 | public function addChildBridge(bridge:IEventDispatcher, bridgeProvider:ISWFBridgeProvider):void |
| 115 | 115 | { |
| ... | ...@@ -120,7 +120,7 @@ |
| 120 | 120 | } |
| 121 | 121 | |
| 122 | 122 | /** |
| 123 | | * @inheritdoc |
| 123 | * @inheritDoc |
| 124 | 124 | */ |
| 125 | 125 | public function removeChildBridge(bridge:IEventDispatcher):void |
| 126 | 126 | { |
| ... | ...@@ -135,7 +135,7 @@ |
| 135 | 135 | } |
| 136 | 136 | |
| 137 | 137 | /** |
| 138 | | * @inheritdoc |
| 138 | * @inheritDoc |
| 139 | 139 | */ |
| 140 | 140 | public function getChildBridgeProvider(bridge:IEventDispatcher):ISWFBridgeProvider |
| 141 | 141 | { |
| ... | ...@@ -146,7 +146,7 @@ |
| 146 | 146 | } |
| 147 | 147 | |
| 148 | 148 | /** |
| 149 | | * @inheritdoc |
| 149 | * @inheritDoc |
| 150 | 150 | */ |
| 151 | 151 | public function getChildBridges():Array |
| 152 | 152 | { |
| ... | ...@@ -161,7 +161,7 @@ |
| 161 | 161 | } |
| 162 | 162 | |
| 163 | 163 | /** |
| 164 | | * @inheritdoc |
| 164 | * @inheritDoc |
| 165 | 165 | */ |
| 166 | 166 | public function containsBridge(bridge:IEventDispatcher):Boolean |
| 167 | 167 | { |
| ... | ...@@ -16,10 +16,9 @@ |
| 16 | 16 | import flash.events.IEventDispatcher;
|
| 17 | 17 |
|
| 18 | 18 | /**
|
| 19 | | * This is an event sent between sandboxes.
|
| 20 | | * The event lets objects in other sandboxes know
|
| 21 | | * what is going on in this sandbox.
|
| 22 | | * The events are informational in nature as opposed to SWFBridgeRequests,
|
| 19 | * This is an event that is sent between applications that are in different security sandboxes.
|
| 20 | * The event lets objects in other sandboxes know what is going on in this sandbox.
|
| 21 | * The events are informational in nature as opposed to a SWFBridgeRequest,
|
| 23 | 22 | * which request an object do something on its behalf.
|
| 24 | 23 | */
|
| 25 | 24 | public class SWFBridgeEvent extends Event
|
| ... | ...@@ -40,23 +39,23 @@ |
| 40 | 39 | "bridgeApplicationActivate";
|
| 41 | 40 |
|
| 42 | 41 | /**
|
| 43 | | * Sent via bridge to a child application's systemManager to notify it
|
| 44 | | * that the SWF is about to be unloaded. The systemManager marshals and
|
| 42 | * Sent through a bridge to a child application's SystemManager to notify it
|
| 43 | * that the SWF is about to be unloaded. The SystemManager marshals and
|
| 45 | 44 | * re-dispatches the event so that application code can remove references
|
| 46 | | * that would prevent the SWF from unloading
|
| 45 | * that would prevent the SWF file from unloading.
|
| 47 | 46 | */
|
| 48 | 47 | public static const BRIDGE_APPLICATION_UNLOADING:String = "bridgeApplicationUnloading";
|
| 49 | 48 |
|
| 50 | 49 | /**
|
| 51 | | * Dispatched via bridges to all other FocusManagers to notify them
|
| 52 | | * that another focus manager is now active.
|
| 50 | * Dispatched through bridges to all other FocusManagers to notify them
|
| 51 | * that another FocusManager is now active.
|
| 53 | 52 | */
|
| 54 | 53 | public static const BRIDGE_FOCUS_MANAGER_ACTIVATE:String =
|
| 55 | 54 | "bridgeFocusManagerActivate";
|
| 56 | 55 |
|
| 57 | 56 | /**
|
| 58 | | * Dispatched via parent bridge to its SWFLoader to notify it
|
| 59 | | * that a new system manager has been initialized.
|
| 57 | * Dispatched through a parent bridge to its SWFLoader to notify it
|
| 58 | * that a new SystemManager has been initialized.
|
| 60 | 59 | */
|
| 61 | 60 | public static const BRIDGE_NEW_APPLICATION:String =
|
| 62 | 61 | "bridgeNewApplication";
|
| ... | ...@@ -66,32 +65,32 @@ |
| 66 | 65 | * a window was activated.
|
| 67 | 66 | *
|
| 68 | 67 | * For a compatible application, the <code>data</code> property
|
| 69 | | * is used as an object with two properties, <code>window</code>
|
| 68 | * is an object with two properties, <code>window</code>
|
| 70 | 69 | * and <code>notifier</code>. The <code>data.window</code> property
|
| 71 | | * is set to the system manager proxy that was activated.
|
| 70 | * is the SystemManager proxy that was activated.
|
| 72 | 71 | * For an untrusted application, the <code>data.window</code> property
|
| 73 | | * is set to a string id of the window. The
|
| 74 | | * <code>data.notifier</code> property is set to the bridge of the
|
| 75 | | * application dispatching the event. The event may be dispatched
|
| 76 | | * directly to a sandbox root instead of over a bridge, so event.target
|
| 77 | | * may not be the bridge of the application dispatching the event.
|
| 72 | * is a string id of the window. The
|
| 73 | * <code>data.notifier</code> property is the bridge of the
|
| 74 | * application dispatching the event. The event might be dispatched
|
| 75 | * directly to a sandbox root instead of over a bridge, so <code>event.target</code>
|
| 76 | * might not be the bridge of the application dispatching the event.
|
| 78 | 77 | */
|
| 79 | 78 | public static const BRIDGE_WINDOW_ACTIVATE:String = "bridgeWindowActivate";
|
| 80 | 79 |
|
| 81 | 80 | /**
|
| 82 | 81 | * Dispatched to a parent bridge or sandbox root to notify it that
|
| 83 | | * the proxy system manager was deactivated.
|
| 82 | * the proxy SystemManager was deactivated.
|
| 84 | 83 | *
|
| 85 | 84 | * For a compatible application, the <code>data</code> property
|
| 86 | | * is used as an object with two properties, <code>window</code>
|
| 85 | * is an object with two properties, <code>window</code>
|
| 87 | 86 | * and <code>notifier</code>. The <code>data.window</code> property
|
| 88 | | * is set to the system manager proxy that was activated.
|
| 87 | * is the SystemManager proxy that was activated.
|
| 89 | 88 | * For an untrusted application, the <code>data.window</code> property
|
| 90 | | * is set to a string id of the window. The
|
| 91 | | * <code>data.notifier</code> property is set to the bridge of the
|
| 92 | | * application dispatching the event. The event may be dispatched
|
| 93 | | * directly to a sandbox root instead of over a bridge, so event.target
|
| 94 | | * may not be the bridge of the application dispatching the event.
|
| 89 | * is a string id of the window. The
|
| 90 | * <code>data.notifier</code> property is the bridge of the
|
| 91 | * application dispatching the event. The event might be dispatched
|
| 92 | * directly to a sandbox root instead of over a bridge, so <code>event.target</code>
|
| 93 | * might not be the bridge of the application dispatching the event.
|
| 95 | 94 | */
|
| 96 | 95 | public static const BRIDGE_WINDOW_DEACTIVATE:String = "brdigeWindowDeactivate";
|
| 97 | 96 |
|
| ... | ...@@ -105,9 +104,9 @@ |
| 105 | 104 | * Marshal a SWFBridgeRequest from a remote ApplicationDomain into the current
|
| 106 | 105 | * ApplicationDomain.
|
| 107 | 106 | *
|
| 108 | | * @param event A SWFBridgeRequest which may have been created in a different ApplicationDomain.
|
| 107 | * @param event A SWFBridgeRequest which might have been created in a different ApplicationDomain.
|
| 109 | 108 | *
|
| 110 | | * @return A SWFBridgeRequest created in the caller's ApplicationDomain.
|
| 109 | * @return A SWFBridgeEvent that was created in the caller's ApplicationDomain.
|
| 111 | 110 | */
|
| 112 | 111 | public static function marshal(event:Event):SWFBridgeEvent
|
| 113 | 112 | {
|
| ... | ...@@ -126,6 +125,16 @@ |
| 126 | 125 |
|
| 127 | 126 | /**
|
| 128 | 127 | * Constructor.
|
| 128 | *
|
| 129 | * @param type The event type; indicates the action that caused the event.
|
| 130 | *
|
| 131 | * @param bubbles Specifies whether the event can bubble up the display list hierarchy.
|
| 132 | *
|
| 133 | * @param cancelable Specifies whether the behavior associated with the event can be prevented.
|
| 134 | *
|
| 135 | * @param data An object that is null by default, but can contain information about the event, depending on the
|
| 136 | * type of event.
|
| 137 | *
|
| 129 | 138 | */
|
| 130 | 139 | public function SWFBridgeEvent(type:String, bubbles:Boolean = false,
|
| 131 | 140 | cancelable:Boolean = false,
|
|