I'm trying to wrap soundmanager2 (
http://www.schillmania.com/projects/soundmanager2/ ) , and in their main
javascript file at the bottom they instantiate a new SoundManager object
called soundManager.

I have this code snippet:

public class SoundManager2 {

    public static native void playSound(String file)
        /*-{

            soundManager.createSound({
                  id: 'aSound',
                  url: 'file.mp3'
            });
            soundManager.play('aSound');


         }-*/
    ;

}

But when I call it I get 'soundManager is undefined'.  If I put this same
javascript in a <script> tag in the host page it executes fine, what gives
?

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to