• 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
Design Question - when to use NSPanel subclass vs. window controller?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Design Question - when to use NSPanel subclass vs. window controller?


  • Subject: Design Question - when to use NSPanel subclass vs. window controller?
  • From: Jim Correia <email@hidden>
  • Date: Sun, 11 May 2003 12:24:20 -0400

Looking at a class dump of AppKit reveals that there are several subclasses of NSPanel.

Obviously any conclusions I draw about the subclasses are going to be at least partially uninformed since I don't have the source. But looking at the instance variables and methods, it would appear that there is lots of controller like functionality baked into the NSPanel subclasses.

My question is this: When should I use a NSPanel subclass vs. using a window controller?

Thus far I use a window controller to deal with the controller aspects of things - outlets, actions, shuffling stuff between the view and the model, and have only subclasses NSPanel when I need to extend or alter the functionality of NSPanel.

This so far has seemed to be a reasonable way to do things, but I want to make sure I'm not missing something subtle or important about the MVC model. (Perhaps there is a reason, historical or other, for the class inheritance tree in AppKit?)

Thanks,
Jim
_______________________________________________
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: Design Question - when to use NSPanel subclass vs. window controller?
      • From: Oscar Morales Vivó <email@hidden>
  • Prev by Date: Re: How to intercept save panel?
  • Next by Date: Printing windows
  • Previous by thread: Re: How to intercept save panel?
  • Next by thread: Re: Design Question - when to use NSPanel subclass vs. window controller?
  • Index(es):
    • Date
    • Thread