Ok, I know that the model for the new graphing vc is going to be a subclass of the calculator brain, but how do I get the program stack of the CalculatorBrain from the old VC to the GraphingBrain of my new VC? DO I have to go down the stack on the Storyboard-segue?
I have the pinching and panning on the new axes setup, as well as the delegate to communicate between the new graph brain and graph vc. But isn't my programStack that the user typed in before "trapped" in the old MVC?
I think I've got the concept down, but I don't see the way for that communication to occur.
Thanks in advance!
***For those who don't follow the course, I have two MVCs linked by the NavigationController. The user enters a series of numbers and operations (in the first MVC) which are stored in are then stored in an array in the model of the first MVC. When a button is pressed, it segues to a new MVC, which needs the array that was entered in the previous MVC. How do I transfer that array between two seemingly separate MVCs? I don't think I can have a property in the second VC and set it from the first VC because it(the second MVC) is not instantiated yet. It maybe something with preparteToSegue but I'm not sure.
Having gone through CS193P (well more than half way there), I think I understand your questions. Here is what you need to remember:
To send a property value down the MVC (C --> V) path and in this case the V holds another MVC; use PrepareForSegue. Regardless of whether the destination has been instantiated or not, you need to do a few things:
Hope this helps and gets the juice flowing...
KMB