FORUMS: list search recent posts

AS3 - VERY annoying double-click issue

COW Forums : Adobe Flash

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Dalton Crosthwait
AS3 - VERY annoying double-click issue
on Jun 29, 2010 at 2:40:46 pm

Hello!

Just a small problem with double clicking. I'm working on a site in AS3, and whenever a button in the navigation is double clicked it sends the playhead to the frame prior to where the gotoAndPlay code tells it to go. I've attempted to disable the double click functionality of the buttons, but to no avail. Here's the code I used to disable it:


//Disable Double Clicks//////////////////
/////////////////////////////////////////
about_btn.doubleClickEnabled = false;
cyo_btn.doubleClickEnabled = false;
favorites_btn.doubleClickEnabled = false;
contact_btn.doubleClickEnabled = false;


Maybe I'm missing something?

Sincerely,
Dalton G Crosthwait

MONSTRO
monstrodesign.com


Return to posts index

Pieter Helsen
Re: AS3 - VERY annoying double-click issue
on Jun 29, 2010 at 2:54:12 pm

The problem is not so much double clicking, as clicking twice, very fast.
Can you tell me what code is on the CLICK event listener for your menu items?

what I would do is disable the item once it is clicked and then re-enable it once you click another item (just remove and add the event listener again)

Kind regards,
Pieter

General notice: from now on, I would like to ask everyone to put [AS2] or [AS3] (corresponding to the version of actionscript you are using on your project) in front of their post titles when the question is actionscript related! Please help us help you faster. Thank you.


Return to posts index

Dalton Crosthwait
Re: AS3 - VERY annoying double-click issue
on Jun 29, 2010 at 3:31:47 pm

Hm. I've never disabled a listener before (probably not a good thing... hahaha).

Here's the code for one of the buttons (they're all coded the same way):


cyo_btn.addEventListener(MouseEvent.MOUSE_DOWN, cyoClick);

function cyoClick(event:MouseEvent):void
{
gotoAndPlay("Create");
}


Thanks so much for the help!

Sincerely,
Dalton G Crosthwait

MONSTRO
monstrodesign.com


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2018 CreativeCOW.net All Rights Reserved
[TOP]