kEventParamClickCount (in, typeUInt32) * Whether this is a single click, double click, etc. In other words, if it's 1, it's a single click, and so on. I'd actually suggest reading through all of CarbonEvents.h. It has a lot of useful data in it that doesn't always come across in the official documentation. Hope this helps, Eric -- Eric Albert edu http://rescomp.stanford.edu/~ejalbert/ [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => [ref] => <1g4kdzi.civb30gkp9ykN%matt@tidbits.com> [htmlstate] => on_nl2br [postusername] => Eric [ip] => ejalbert@stanfo [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 6 [islastshown] => [isfirstshown] => [attachments] => [allattachments] => ) --> detecting double click event - Mac Programming

detecting double click event - Mac Programming

Keith Wiley <unm.edu> wrote:   Every event tells you whether it's a double-click (see NSEvent and clickCount), and some widgets (such as tables) send an action event specifically if you double-click. m. -- matt neuburg, phd = com, http://www.tidbits.com/matt/ Read TidBITS! It's free and smart. http://www.tidbits.com...

  1. #1

    Default Re: detecting double click event

    Keith Wiley <unm.edu> wrote:
     

    Every event tells you whether it's a double-click (see NSEvent and
    clickCount), and some widgets (such as tables) send an action event
    specifically if you double-click. m.

    --
    matt neuburg, phd = com, http://www.tidbits.com/matt/
    Read TidBITS! It's free and smart. http://www.tidbits.com
    matt Guest

  2. #2

    Default detecting double click event

    I have found the DblTime function, so I guess I could put in an Event
    Handler for Mouse up events, remember the time, and calculate the duration
    to the next Mouse down event, but I'm wondering if every Mouse down has
    this in it already somewhere, simply as a parameter as to whether or not
    it is the second click of a double click.

    Yes, no?

    __________________________________________________ ______________________
    Keith Wiley unm.edu
    http://www.unm.edu/~keithw http://www.mp3.com/KeithWiley

    "Yet mark his perfect self-contentment, and hence learn his lesson,
    that to be self-contented is to be vile and ignorant, and that to
    aspire is better than to be blindly and impotently happy."
    -- Edwin A. Abbott, Flatland
    __________________________________________________ ______________________
    Keith Guest

  3. #3

    Default Re: detecting double click event

    In article <cs.unm.edu>,
    Keith Wiley <unm.edu> wrote:
     

    Yes, you should use the API to determine if its a double-click. Keep in
    mind that the length of a double click is user settable in System
    Preferences, therefore you really shouldn't even try to do it yourself.

    --
    |\/| /| |2 |<
    mehaase(at)sas(dot)upenn(dot)edu
    Mark Guest

  4. #4

    Default Re: detecting double click event

    On Mon, 17 Nov 2003, matt neuburg wrote:
     
    >
    > Every event tells you whether it's a double-click (see NSEvent and
    > clickCount), and some widgets (such as tables) send an action event
    > specifically if you double-click. m.[/ref]

    Or in carbon you want the kEventParamClickCount parameter.

    Fred

    Frederick Guest

  5. #5

    Default Re: detecting double click event

    On Mon, 17 Nov 2003, Frederick Cheung wrote:
     

    Yeah, well, I saw this parameter in the docs, but there isn't any
    doentation at all as to what the parameter actually is or means, so I'm
    unsure how to use it. It's an unsigned int, so what does that mean, it's
    the duration of time since the last click, or it's the Nth click in a
    series of clicks, or what? Developer.apple.com is just useless about this
    sort of stuff. It lists kEventParamClickCount in numerous places, but
    doesn't explain the keyword even once.

    Any explanation is appreciated. Thanks.

    __________________________________________________ ______________________
    Keith Wiley unm.edu
    http://www.unm.edu/~keithw http://www.mp3.com/KeithWiley

    "Yet mark his perfect self-contentment, and hence learn his lesson,
    that to be self-contented is to be vile and ignorant, and that to
    aspire is better than to be blindly and impotently happy."
    -- Edwin A. Abbott, Flatland
    __________________________________________________ ______________________
    Keith Guest

  6. #6

    Default Re: detecting double click event

    In article <cs.unm.edu>,
    Keith Wiley <unm.edu> wrote:
     
    >
    > Yeah, well, I saw this parameter in the docs, but there isn't any
    > doentation at all as to what the parameter actually is or means, so I'm
    > unsure how to use it. It's an unsigned int, so what does that mean, it's
    > the duration of time since the last click, or it's the Nth click in a
    > series of clicks, or what? Developer.apple.com is just useless about this
    > sort of stuff. It lists kEventParamClickCount in numerous places, but
    > doesn't explain the keyword even once.[/ref]

    When in doubt, read the headers. From CarbonEvents.h:

    * --> kEventParamClickCount (in, typeUInt32)
    * Whether this is a single click, double click, etc.

    In other words, if it's 1, it's a single click, and so on.

    I'd actually suggest reading through all of CarbonEvents.h. It has a
    lot of useful data in it that doesn't always come across in the official
    doentation.

    Hope this helps,
    Eric

    --
    Eric Albert edu
    http://rescomp.stanford.edu/~ejalbert/
    Eric Guest

  7. #7

    Default Re: detecting double click event

    In article <cs.unm.edu>,
    Keith Wiley <unm.edu> wrote:
     
    >
    > Yeah, well, I saw this parameter in the docs, but there isn't any
    > doentation at all as to what the parameter actually is or means, so I'm
    > unsure how to use it. It's an unsigned int, so what does that mean, it's
    > the duration of time since the last click, or it's the Nth click in a
    > series of clicks, or what? Developer.apple.com is just useless about this
    > sort of stuff. It lists kEventParamClickCount in numerous places, but
    > doesn't explain the keyword even once.[/ref]

    Actually, the second hit in a google search for "kEventParamClickCount
    site:apple.com" has a very nice discussion about it. (It's at
    http://developer.apple.com/doentation/Carbon/Conceptual/Carbon_Event_M
    anager/Tasks/chapter_3_section_10.html) I always use Google to search
    Apple's site, never Apple's search. Heck, I always use Google to search
    *any* site that Google actually indexes, they're inevitably better than
    whatever home-grown search people have.

    (Actually, in this case, Apple's search is "Powered by Google". They
    have a link to the same page, search for kEventParamClickCount on
    developer.apple.com and it's the third hit. But I find Google easier to
    work with anyway.)
    Michael Guest

  8. #8

    Default Re: detecting double click event

    In article <mail-A0E1DD.10391418112003localhost>,
    Michael Ash <com> wrote:
     

    I believe that Apple's own index includes the sample code, and Google's doesn't,
    but I could be wrong.

    meeroh

    --
    If this message helped you, consider buying an item
    from my wish list: <http://web.meeroh.org/wishlist>

    Miro Guest

Similar Threads

  1. Double-click Event Attribute on Datagrid Item
    By Alan Z. Scharf in forum ASP.NET Data Grid Control
    Replies: 2
    Last Post: June 11th, 12:41 PM
  2. double click causes click-event anddoubleClick-event
    By jpsouthern in forum Macromedia Flex General Discussion
    Replies: 1
    Last Post: April 14th, 09:27 PM
  3. Group Item Icon can listen to double click event?
    By calebmei in forum Macromedia Flex General Discussion
    Replies: 5
    Last Post: April 11th, 05:05 PM
  4. Detect a double click event
    By nicolas_PUSET@adobeforums.com in forum Adobe Acrobat SDK
    Replies: 2
    Last Post: April 2nd, 12:05 PM
  5. Double click event in DataGrid
    By kohinoor75 in forum Macromedia Flex General Discussion
    Replies: 1
    Last Post: September 6th, 03:43 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •