Movieclip._Droptarget - MACROMEDIA FLASH MX 2004-ACTIONSCRIPT LANGUAGE Reference

Actionscript language reference
Table of Contents

Advertisement

MovieClip._droptarget

Availability
Flash Player 4.
Usage
my_mc._droptarget:String
Description
Read-only property; returns the absolute path in slash syntax notation of the movie clip instance
on which
my_mc
slash (
). To compare the
/
function to convert the returned value from slash syntax to a dot syntax reference.
Note: You must perform this conversion if you are using ActionScript 2.0, which does not support
slash syntax.
Example
The following example evaluates the
instance and uses
reference is then compared to the reference to the
garbage_mc
If the two references are equivalent, the visibility of
equivalent, the
garbage
origX = garbage_mc._x;
origY = garbage_mc._y;
garbage_mc.onPress = function() {
this.startDrag();
};
garbage_mc.onRelease = function() {
this.stopDrag();
if (eval(this._droptarget) == trashcan_mc) {
this._visible = false;
} else {
this._x = origX;
this._y = origY;
}
};
See also
startDrag(),
510
Chapter 2: ActionScript Language Reference
was dropped. The
_droptarget
_droptarget
_droptarget
to convert it from slash syntax to a dot syntax reference. The
eval()
instance resets to its original position.
stopDrag()
property always returns a path that starts with a
property of an instance to a reference, use the
property of the
garbage_mc
movie clip
garbage_mc
movie clip instance.
trashcan_mc
is set to
. If they are not
false
eval()

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FLASH MX 2004-ACTIONSCRIPT LANGUAGE and is the answer not in the manual?

Questions and answers

This manual is also suitable for:

Flash mx

Table of Contents