• 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
Fwd: Modifier keys and panther...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Fwd: Modifier keys and panther...


  • Subject: Fwd: Modifier keys and panther...
  • From: Jiva DeVoe <email@hidden>
  • Date: Tue, 16 Dec 2003 11:51:04 -0700

Quoth an ancient, wiser man than I: "Duh..." This got it fixed, please
ignore this email now. :)

Begin forwarded message:

> From: Jonathan Wight <email@hidden>
> Date: December 16, 2003 11:46:10 AM MST
> To: Jiva DeVoe <email@hidden>
> Subject: Re: Modifier keys and panther...
>
> You want to use "&" instead of "&&" in your if statement.
>
> Jon.
>
> On Dec 16, 2003, at 12:13, Jiva DeVoe wrote:
>
>> I'm having a strange problem with modifier keys. I have an NSView
>> that
>> looks for the mouse down event, when the event comes in it seems to
>> always have the shift modifier. Here's the code.
>>
>> -(void)mouseDown:(NSEvent *)event
>> {
>> if([event modifierFlags] && NSShiftKeyMask)
>> [self addToSelection:[self convertPoint:[event
>> locationInWindow] fromView:nil]];
>> else
>> [self selectCardAt:[self convertPoint:[event
>> locationInWindow] fromView:nil]];
>> }
>>
>> This worked fine under Jaguar seems to have only started happening in
>> panther. In the debugger, the [event modifierFlags] comes back as
>> 256.
>>
>> What am I doing wrong? Or, if I am not doing anything wrong, anyone
>> have any clues? If you see this code and say "That's correct" please
>> let me know that too, so I won't wonder.
>>
>> --
>> Jiva DeVoe
>> jiva at devoesquared.com
>> http://www.devoesquared.com
>>
>> [demime 0.98b removed an attachment of type
>> application/pkcs7-signature which had a name of smime.p7s]
>> _______________________________________________
>> 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.
>>
>>
--
Jiva DeVoe
jiva at devoesquared.com
http://www.devoesquared.com

[demime 0.98b removed an attachment of type application/pkcs7-signature which had a name of smime.p7s]
_______________________________________________
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.

  • Prev by Date: Developing for 10.3
  • Next by Date: Re: Modifier keys and panther...
  • Previous by thread: Re: Modifier keys and panther...
  • Next by thread: NSFont system help or documentation needed
  • Index(es):
    • Date
    • Thread