• 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
Initializing views with models
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Initializing views with models


  • Subject: Initializing views with models
  • From: Edwin Vane <email@hidden>
  • Date: Tue, 26 Jul 2005 13:53:40 -0400
  • Mail-followup-to: Cocoa-Dev <email@hidden>

Hi,

I'm new to Cocoa and I'm working on wrapping my head around how objects
communicate in the framework. I'm looking for the 'Cocoa way' for the
following problem:

I have an NSWindow filled with custom and standard NSView-derived
objects and controls. From what I understand of the MVC pattern, these
things make up the View. What I'd like to happen is to make a window
appear but before it appears to initialize the internal views with links to particular
model objects (taken from a document perhaps although for now I've just
hardcoded one set of model objects).

So which object should provide the view with links to the model? The
window resides in a nib file and is not visible by default. Right now I
have a subclassed NSWindowController that will make the window visible
in response to some action. Should the WindowController do the
view->model linking (before the window is made visible) or should something else?

--

Edwin Vane
   MMath Candidate
   Computer Graphics Lab
   School of Computer Science
   University of Waterloo

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Initializing views with models
      • From: Andreas Mayer <email@hidden>
  • Prev by Date: Re: multi-character character constant and CFString
  • Next by Date: Re: Exception handling help
  • Previous by thread: Style/Design question - when and how to authorise
  • Next by thread: Re: Initializing views with models
  • Index(es):
    • Date
    • Thread