• 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: NSView -subviews ordering?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSView -subviews ordering?


  • Subject: Re: NSView -subviews ordering?
  • From: Brock Brandenberg <email@hidden>
  • Date: Wed, 29 May 2002 14:53:34 -0500

Hi Ondra.

You can also re-order your subviews using sortSubviewsUsingFunction:context:. Its documentation is pretty accurate,
except that Apple doesn't make it clear that it should be a C function, not an object method,

That's self-evident -- otherwise it would be ...UsingSelector, not function.

True. I've seen two previous posts from individuals not being able to make it work, though, and this was the reason, so I thought I'd reinforce the point.

so you need to put it outside of your @implementation/@end or in an external file.

You don't need to do that. Why, on earth?!?

I use the same sort function with a couple of NSView subclasses, so I simply put it in a file that gets included by both rather than duplicate code.

Brock

----- industrial design @ bergdesign.com ------
_______________________________________________
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: NSView -subviews ordering?
      • From: Ondra Cada <email@hidden>
References: 
 >Re: NSView -subviews ordering? (From: Ondra Cada <email@hidden>)

  • Prev by Date: NSOutlineView and DO
  • Next by Date: Re: copyPath on different volumes with same name
  • Previous by thread: Re: NSView -subviews ordering?
  • Next by thread: Re: NSView -subviews ordering?
  • Index(es):
    • Date
    • Thread