mouseLevel
Usage
-- Lingo syntax
spriteObjRef.mouseLevel
// JavaScript syntax
spriteObjRef.mouseLevel;
Description
QuickTime sprite property; controls how Director passes mouse clicks on a QuickTime sprite
to QuickTime. The ability to pass mouse clicks within the sprite's bounding rectangle can be
useful for interactive media such as QuickTime VR. The
these values:
•
#controller
only to mouse clicks that occur outside the controller. This is the standard behavior for
QuickTime sprites other than QuickTime VR.
•
—Passes all mouse clicks within the sprite's bounding rectangle to QuickTime. No clicks
#all
pass to other Lingo handlers.
•
—Does not pass any mouse clicks to QuickTime. Director responds to all mouse clicks.
#none
•
—Passes all mouse clicks within a QuickTime VR sprite's bounding rectangle to
#shared
QuickTime and then passes these events to Lingo handlers. This is the default value for
QuickTime VR.
This property can be tested and set.
Example
This frame script checks to see if the name of the QuickTime sprite in channel 5 contains the
string "QTVR." If it does, this script sets
.
#none
-- Lingo syntax
on prepareFrame
if sprite(5).member.name contains "QTVR" then
sprite(5).mouseLevel = #all
else
sprite(5).mouseLevel = #none
end if
end
// JavaScript syntax
function prepareFrame() {
var nm = sprite(5).member.name;
var nmStr = nm.indexOf("QTVR");
if (nmStr != -1) {
sprite(5).mouseLevel = symbol("all");
} else {
sprite(5).mouseLevel = symbol("none");
}
}
874
Chapter 14: Properties
—Passes clicks only on the movie controller to QuickTime. Director responds
mouseLevel
to
; otherwise, it sets
mouseLevel
#all
sprite property can have
mouseLevel
to
Need help?
Do you have a question about the DIRECTOR MX 2004-DIRECTOR SCRIPTING and is the answer not in the manual?
Questions and answers