• 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: Key down issue
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Key down issue


  • Subject: Re: Key down issue
  • From: Michael Hudson <email@hidden>
  • Date: Fri, 07 Nov 2003 15:30:10 +0000

Denis Vaillant <email@hidden> writes:

> Hi everybody,
>
> I am experiencing a little problem with the keyDown method
>
>
> I have wrote this code
> -(void)keyDown:(NSEvent *)theEvent
> {
> NSLog(@"[key down] : %@", [theEvent characters]);
> }
>
> In the log window, while pressing the 4 key, I get that :
> 2003-11-07 16:05:15.218 Cocoa OpenGL[2356] [key down] : 4
> 2003-11-07 16:05:15.718 Cocoa OpenGL[2356] [key down] : 4
> 2003-11-07 16:05:15.801 Cocoa OpenGL[2356] [key down] : 4
> 2003-11-07 16:05:15.885 Cocoa OpenGL[2356] [key down] : 4
> 2003-11-07 16:05:15.968 Cocoa OpenGL[2356] [key down] : 4
> 2003-11-07 16:05:16.052 Cocoa OpenGL[2356] [key down] : 4
> 2003-11-07 16:05:16.135 Cocoa OpenGL[2356] [key down] : 4
>
> I do not understand why there is delay of half a second between the first
> and the second time cocoa executes the method while it takes less than 0.01s
> after ?

Isn't this just the standard 'delay before key repeat' thing?

> Is it possible to remove this delay ?

Well, you can twiddle System Preferences, but I don't know if there's
a way to override it for just your application.

Cheers,
mwh

--
Or here's an even simpler indicator of how much C++ sucks: Print
out the C++ Public Review Document. Have someone hold it about
three feet above your head and then drop it. Thus you will be
enlightened. -- Thant Tessman
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Key down issue
      • From: Alastair Houghton <email@hidden>
References: 
 >Key down issue (From: Denis Vaillant <email@hidden>)

  • Prev by Date: Searching for Frameworks
  • Next by Date: RE: Re: Security Framework: Authori(s/z)ion Rights
  • Previous by thread: Key down issue
  • Next by thread: Re: Key down issue
  • Index(es):
    • Date
    • Thread