• 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: Unexpected mouse-handling behaviour
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Unexpected mouse-handling behaviour


  • Subject: Re: Unexpected mouse-handling behaviour
  • From: Michael Ash <email@hidden>
  • Date: Mon, 23 Feb 2009 09:15:44 -0500

On Mon, Feb 23, 2009 at 8:45 AM, Manuel Meyer <email@hidden> wrote:
> Hmm, the endPoint and startingPoint are just helpers right now to visualize
> the mouse interaction. I haven't done any coding on the vertices between two
> Nodes yet.
> I wanted to connect the Nodes without using the superview, but maybe I have
> to? What is the best way to find out, what View(s) are located at a certain
> point?

Certainly you don't have to use the superview, since you can run
equivalent code in either place. Which would be the better design,
that's hard to say. Personally I would use the superview rather than
the subviews, but obviously that's up to you.

You can find the view at any given location by using the -hitTest:
method of NSView. Be careful of the coordinate system of the point
that it takes, as it's a little unusual. You can use that to see what
view the mouse is over in the -mouseUp: method, and then communicate
with it to hook things up if it's the right kind of view.

Mike
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Unexpected mouse-handling behaviour (From: Manuel Meyer <email@hidden>)
 >Re: Unexpected mouse-handling behaviour (From: Andy Lee <email@hidden>)
 >Re: Unexpected mouse-handling behaviour (From: Manuel Meyer <email@hidden>)

  • Prev by Date: Re: object wrapper for an opaque pointer
  • Next by Date: Re: [Q] Re: NSPersistentStore -addPersistentStoreWithType
  • Previous by thread: Re: Unexpected mouse-handling behaviour
  • Next by thread: Re: Unexpected mouse-handling behaviour
  • Index(es):
    • Date
    • Thread