• 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
Drag operations and AppKit views
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Drag operations and AppKit views


  • Subject: Drag operations and AppKit views
  • From: Steve Ivy <email@hidden>
  • Date: Sat, 28 Sep 2002 08:38:52 -0700

I'm trying to add drag-n-drop to my application, following the sample code found here:

http://ranchero.com/software/netnewswire/rssclipboard.php

This example (like Cocoa Programming for Mac OS X) uses a custom view as the drag destination - presumably b/c it's the simplest to demonstrate with. If I add this veiw to my project, I can add it to my application's GUi and it works. So far so good. However, if I want to use any other kind of existing NSView as my drag destination, nothing works right. I've tried NSTextField, NSimageView, even NSTabView (trying to get the contentRect to highlight) to no avail.

In each case I added the drag operation code from RSSDropView.m (in the above sample code) to a subclass of the particular view I was trying, and adjusted the drawRect: method for each one (to perform some sort of highlighting). But it seems that none of these subclassed views actually *get* the drag messages called on them.

Of course there's something I'm not seeing here - can anyone give me some direction?

--Steve
_______________________________________________
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: Drag operations and AppKit views
      • From: Ryan Dingman <email@hidden>
  • Prev by Date: How come bundle is just compiling as a folder?
  • Next by Date: Re: NSImageView scrolling
  • Previous by thread: Re: [NEWBIE QUESTION] What message is sent when window contents finish loading? (revisited)
  • Next by thread: Re: Drag operations and AppKit views
  • Index(es):
    • Date
    • Thread