• 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: Question about Apple's updated Sketch-112 program
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Question about Apple's updated Sketch-112 program


  • Subject: Re: Question about Apple's updated Sketch-112 program
  • From: Graham Cox <email@hidden>
  • Date: Thu, 15 Oct 2009 09:42:15 +1100


On 15/10/2009, at 12:44 AM, Michael de Haan wrote:

- (void)invalidateGraphic:(SKTGraphic *)graphic {
NSArray *windowControllers = [self windowControllers];
[windowControllers makeObjectsPerformSelector:@selector (invalidateGraphic:) withObject:graphic];}
I **think** I see what each line is doing, but, fail to grasp the overall essence of the call.


When a graphic is inserted into the data model, the view that displays it must be updated so that it gets drawn. Since there can be multiple window controllers each having one or more views of the data model, this call ensures that they all get the message. I haven't checked but I suspect if you follow the trail of where -invalidateGraphic: goes, it ends up calling -setNeedsDisplayInRect: on a view somewhere.

--Graham


_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Question about Apple's updated Sketch-112 program (From: Michael de Haan <email@hidden>)

  • Prev by Date: Help with NSURLConnection memory fault
  • Next by Date: Re: SelectedRowIndexes
  • Previous by thread: [SOLVED] Re: Question about Apple's updated Sketch-112 program
  • Next by thread: Examples of MVC pattern with Core Data
  • Index(es):
    • Date
    • Thread