• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: iTunes-like single-click table cell editing
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: iTunes-like single-click table cell editing


  • Subject: Re: iTunes-like single-click table cell editing
  • From: Ryan Stevens <email@hidden>
  • Date: Wed, 19 Jan 2005 07:18:51 -0800

On Jan 19, 2005, at 5:38 AM, M. Uli Kusterer wrote:

At 1:13 Uhr +0100 19.01.2005, Benjámin Salánki wrote:
now the problem is that my table starts editing right after the first click of the double click. i tried looking for [theEvent clickCount], but it turns out mouseDown is called after every click, so when I NSLog it I get 1 (editing code starts) and 2, which starts the doubleAction for the table.

do you know how to fix this?

Someone sent me code for UKDistributedView to do that. What you essentially do is register a timer that fires a little after the double click delay. This timer only starts editing of the cell. Whenever a click happens on a cell, you invalidate and release this timer.


Thus, when a user clicks at the line once, it will take a little time, then the timer will fire and the cell will edit. When a user double-clicks the cell, the second click will remove the timer, and the cell won't edit.


I wonder then, is it easy to get the actual delay time as set in System Preferences? Couldn't your timer fire before a second click is received if you don't use delay+some?


Pretty smart way to do it btw.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: iTunes-like single-click table cell editing
      • From: "M. Uli Kusterer" <email@hidden>
References: 
 >iTunes-like single-click table cell editing (From: Benjámin Salánki <email@hidden>)
 >Re: iTunes-like single-click table cell editing (From: Camillo Lugaresi <email@hidden>)
 >Re: iTunes-like single-click table cell editing (From: Benjámin Salánki <email@hidden>)
 >Re: iTunes-like single-click table cell editing (From: "M. Uli Kusterer" <email@hidden>)

  • Prev by Date: Re: Why do "loose" nibs take precedence over nibs in .lproj?
  • Next by Date: Re: Breakpoint on @throw?
  • Previous by thread: Re: iTunes-like single-click table cell editing
  • Next by thread: Re: iTunes-like single-click table cell editing
  • Index(es):
    • Date
    • Thread