Skip to main content
May 28, 2007
Answered

double click

  • May 28, 2007
  • 3 replies
  • 497 views
Hi

I want to add a double clik detect to a movie clip which works fine and dandy if the movie clip jsut has gaprhics in it. However, i really could do with having th emovie clip also house other movie clips. But when i od this the double click doesnt seem to work. heres the cide bewlow:

var bubble:MovieClip;
bubble = new bubble_container();
this.addChild(bubble);
bubble.doubleClickEnabled = true;
bubble.addEventListener("doubleClick", doubleClick);

bubble.addEventListener("click", singleClik)

function doubleClick(event:Event){
trace("im double clikked");

}

function singleClik(event:Event){
trace("im single clikked");
}

is there a way of basically listenting for anything in bubble being double clicked?

thanks v much in advance

a
This topic has been closed for replies.
Correct answer
my god im a fool:) thanks that works. jesus i should have thougth of that:|

3 replies

kglad
Community Expert
Community Expert
May 28, 2007
you're welcome.
kglad
Community Expert
Community Expert
May 28, 2007
oh, just enable the child.
Correct answer
May 28, 2007
my god im a fool:) thanks that works. jesus i should have thougth of that:|
kglad
Community Expert
Community Expert
May 28, 2007
try:

May 28, 2007
thanks kglad but that doesnt seem to do the trick. What im trying to solve is how to make the nested clip within bubble respond to a double click. the single click works fine everytime. To be clearer I have a movie clip "bubble_container" in my library which also contaisn antoher movie clip which is the actual bubble. If i break this apart the double click works fine, but if keep it as it is the double click does not pick up on anyhting. any ideas?