Skip to content

Commit

Permalink
MoveEvent.as and ValidationResultEvent.as Added (#149)
Browse files Browse the repository at this point in the history
* MoveEvent.as Copied FlexSDK->Royale

mx.events.MoveEvent Copied FlexSDK->Royale

* Update MXRoyaleClasses.as for MoveEvent

Update MXRoyaleClasses.as for MoveEvent

* Update MoveEvent.as

Update MoveEvent.as

* ValidationResultEvent.as FlexSDK->Royale

mx.events.ValidationResultEvent FlexSDK->Royale

* Update ValidationResultEvent.as

Update ValidationResultEvent.as

* Update MXRoyaleClasses.as : ValidationResultEvent

Update MXRoyaleClasses.as for  ValidationResultEvent

* MoveEvent Product Version Updated

MoveEvent Product Version Updated

* ValidationResultEvent Productversion Updated

ValidationResultEvent Productversion Updated
  • Loading branch information
alinakazi authored and pentapache committed Apr 6, 2018
1 parent 87cf932 commit 43641c2
Show file tree
Hide file tree
Showing 3 changed files with 402 additions and 0 deletions.
Expand Up @@ -37,6 +37,8 @@ internal class MXRoyaleClasses
import mx.containers.ControlBar; ControlBar;
import mx.controls.ToolTip; ToolTip;
import mx.controls.beads.ToolTipBead; ToolTipBead;
import mx.events.MoveEvent; MoveEvent;
import mx.events.ValidationResultEvent; ValidationResultEvent;
import mx.containers.Tile; Tile;
import mx.containers.DividedBox; DividedBox;
import mx.containers.beads.ApplicationLayout; ApplicationLayout;
Expand Down
161 changes: 161 additions & 0 deletions frameworks/projects/MXRoyale/src/main/royale/mx/events/MoveEvent.as
@@ -0,0 +1,161 @@
////////////////////////////////////////////////////////////////////////////////
//
// Licensed to the Apache Software Foundation (ASF) under one or more
// contributor license agreements. See the NOTICE file distributed with
// this work for additional information regarding copyright ownership.
// The ASF licenses this file to You under the Apache License, Version 2.0
// (the "License"); you may not use this file except in compliance with
// the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
////////////////////////////////////////////////////////////////////////////////

package mx.events
{
/* import mx.events.Event;*/
import org.apache.royale.events.Event;
import org.apache.royale.events.IRoyaleEvent;
/**
* Represents event objects that are dispatched when a Flex component moves.
*
* @see mx.core.UIComponent
*
* @langversion 3.0
* @playerversion Flash 9
* @playerversion AIR 1.1
* @productversion Royale 0.9.3
* @royalesuppresspublicvarwarning
*/
public class MoveEvent extends Event
{
/* include "../core/Version.as"; */

//--------------------------------------------------------------------------
//
// Class constants
//
//--------------------------------------------------------------------------

/**
* The <code>MoveEvent.MOVE</code> constant defines the value of the
* <code>type</code> property of the event object for a <code>move</code> event.
*
* <p>The properties of the event object have the following values:</p>
* <table class="innertable">
* <tr><th>Property</th><th>Value</th></tr>
* <tr><td><code>bubbles</code></td><td>false</td></tr>
* <tr><td><code>cancelable</code></td><td>false</td></tr>
* <tr><td><code>currentTarget</code></td><td>The Object that defines the
* event listener that handles the event. For example, if you use
* <code>myButton.addEventListener()</code> to register an event listener,
* myButton is the value of the <code>currentTarget</code>. </td></tr>
* <tr><td><code>oldX</code></td><td>The previous x coordinate of the object, in pixels.</td></tr>
* <tr><td><code>oldY</code></td><td>The previous y coordinate of the object, in pixels.</td></tr>
* <tr><td><code>target</code></td><td>The Object that dispatched the event;
* it is not always the Object listening for the event.
* Use the <code>currentTarget</code> property to always access the
* Object listening for the event.</td></tr>
* </table>
*
* @eventType move
*
* @langversion 3.0
* @playerversion Flash 9
* @playerversion AIR 1.1
* @productversion Royale 0.9.3
*/
public static const MOVE:String = "move";

//--------------------------------------------------------------------------
//
// Constructor
//
//--------------------------------------------------------------------------

/**
* Constructor.
*
* @param type The event type; indicates the action that caused the event.
*
* @param bubbles Specifies whether the event can bubble
* up the display list hierarchy.
*
* @param cancelable Specifies whether the behavior
* associated with the event can be prevented.
*
* @param oldX The previous x coordinate of the object, in pixels.
*
* @param oldY The previous y coordinate of the object, in pixels.
*
* @langversion 3.0
* @playerversion Flash 9
* @playerversion AIR 1.1
* @productversion Royale 0.9.3
*/
public function MoveEvent(type:String, bubbles:Boolean = false,
cancelable:Boolean = false,
oldX:Number = NaN, oldY:Number = NaN)
{
super(type, bubbles, cancelable);

this.oldX = oldX;
this.oldY = oldY;
}

//--------------------------------------------------------------------------
//
// Properties
//
//--------------------------------------------------------------------------

//----------------------------------
// oldX
//----------------------------------

/**
* The previous <code>x</code> coordinate of the object, in pixels.
*
* @langversion 3.0
* @playerversion Flash 9
* @playerversion AIR 1.1
* @productversion Royale 0.9.3
*/
public var oldX:Number;

//----------------------------------
// oldY
//----------------------------------

/**
* The previous <code>y</code> coordinate of the object, in pixels.
*
* @langversion 3.0
* @playerversion Flash 9
* @playerversion AIR 1.1
* @productversion Royale 0.9.3
*/
public var oldY:Number;

//--------------------------------------------------------------------------
//
// Overridden methods: Event
//
//--------------------------------------------------------------------------

/**
* @private
*/
override public function cloneEvent():IRoyaleEvent
{
return new MoveEvent(type, bubbles, cancelable, oldX, oldY);
}
}

}

0 comments on commit 43641c2

Please sign in to comment.