EasyManua.ls Logo

MACROMEDIA FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE - Point (Flash.geom.point)

MACROMEDIA FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE
1378 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Point (flash.geom.Point) 1009
// Return the value of newVal.
return newVal;
}
// Use watch() to register the event handler, passing as parameters:
// - the name of the property to watch: "speed"
// - a reference to the callback function speedWatcher
// - the speedLimit of 55 as the userData parameter
myObject.watch("speed", speedWatcher, 55);
// set the speed property to 54, then to 57
myObject.speed = 54; // output: You are not speeding
myObject.speed = 57; // output: You are speeding
// unwatch the object
myObject.unwatch("speed");
myObject.speed = 54; // there should be no output
See also
addProperty (Object.addProperty method), unwatch (Object.unwatch method)
Point (flash.geom.Point)
Object
|
+-flash.geom.Point
public class Point
extends Object
The Point class represents a location in a two-dimensional coordinate system, where x
represents the horizontal axis and y represents the vertical axis.
The following code creates a point at (0,0):
var myPoint:Point = new Point();
Availability: ActionScript 1.0; Flash Player 8
Property summary
Modifiers Property Description
length:Number The length of the line segment from (0,0) to this point.
x:Number The horizontal coordinate of the point.
y:Number The vertical coordinate of the point.

Table of Contents

Related product manuals