Update on defaultStack problem

Richard Gaskin ambassador at fourthworld.com
Tue Feb 1 14:54:19 EST 2011


DunbarX wrote:

> I think a note is definitely called for. I would test the
> doubleclickinterval just a little more, but I have never found it to help at all.

Given how rare it is that a UI will use both messages in a single 
control, the doubleClickInterval is equally uncommonly used.

But the one place it can help is exactly the handler you provided:

  on mouseUp
     wait 15 --your comfort level
     if the mouseClick then doDoubleStuff
     else doSingleStuff
  end mouseUp

The comfort level that matters most is that of the end-user. :)

Instead of "wait 15" you could use the doubleClickInterval, which is the 
number of milliseconds the user has their system set to use as a 
double-click threshold:

  on mouseUp
     wait the doubleClickInterval millisecs
     if the mouseClick then doDoubleStuff
     else doSingleStuff
  end mouseUp


--
  Richard Gaskin
  Fourth World
  LiveCode training and consulting: http://www.fourthworld.com
  Webzine for LiveCode developers: http://www.LiveCodeJournal.com
  LiveCode Journal blog: http://LiveCodejournal.com/blog.irv




More information about the use-livecode mailing list