• 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
OutlineView doesn't display correct cell [SOLVED]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

OutlineView doesn't display correct cell [SOLVED]


  • Subject: OutlineView doesn't display correct cell [SOLVED]
  • From: Tom Sutcliffe <email@hidden>
  • Date: Sun, 20 Jul 2003 21:33:41 +0100

I came across this problem recently but found a solution just before posting to the list. So, just for the archives...

The DragNDropOutlineView AppKit example does something really nasty which can trip you up if you base a project on its implementation of ImageAndTextCell. I used this cell but changed the NSImageCell to an NSButtonCell, and had strange problems with redrawing when clicking on rows in the OutlineView before releasing the mouse button. These went away when I changed the implementation of copyWithZone to copy the extra cell I used instead of retaining it (which is what the example does). Obviously copyWithZone should always create "a functionally independent object" which for some odd reason is essential in NSOutlineView's row highlighting technique.

Just a heads up for anyone wondering why on earth their example-based OutlineViews don't work as planned.

Regards,

Tom
_______________________________________________
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: Re: unresponsive button in panel
  • Next by Date: Re: Cells within cells and mouse tracking
  • Previous by thread: Re: Compiler Craziness!
  • Next by thread: #import problem
  • Index(es):
    • Date
    • Thread