Vipin:

My initial thought is to trap for the alt key in director. If the projector
detects the key is pressed, send a call to a function in your SWF.

<Director Lingo-- I usually place this code in a movie script labeled "start
movie">

-- prepareMovie is called before first frame is loaded
on prepareMovie
    -- keyDownScript assigns a function for capturing and handling
    -- all keys pressed.
    keyDownScript = "checkKeys"
end prepareMovie

on checkKeys
    -- Check to see if the keys are pressed. If they are call to SWF
    --
    -- _key.key uses the (ANSI) value that is assigned to the key, not the
    -- numerical value. _key.keyCode uses the numerical value, not the
    -- American National Standards Institute (ANSI) value.
    if (_key.optionDown and _key.key = "j") then
        -- If the AS function is in the _root timeline call with this syntax
        sprite(flashSprite).altPressed()
        -- If the AS function is in a clip timeline call with this syntax
        sprite(flashSprite).myClip.altPressed()
    else
        put "Key pressed ="&&_key.key
    end if
end checkKeys

Hope this helps...

Andrew Rost
Electronic Learning Specialist
IDEXX Computer Systems
www.idexx.com
-----Original Message-----
From: vipin chandran [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, January 10, 2007 6:24 AM
To: Open Source Flash Mailing List
Subject: [Flashcoders] Problem capturing the ALT key

Hello All,

I am doing a project where we are embedding a flash swf in director and
making projector.

My problem hers is when i am in the projector, the ALT key is not getting
captured.

And i really need this for giving one short-cut key. (The client is mad
about it).

Please help me if you have any solution for this.

Thanks'
Vipin
_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com
_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to