• 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: an interesting delegate design issue raised by IB...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: an interesting delegate design issue raised by IB...


  • Subject: Re: an interesting delegate design issue raised by IB...
  • From: Ondra Cada <email@hidden>
  • Date: Wed, 12 Sep 2001 19:39:39 +0200

Michael,

>>>>>> Michael B. Johnson (MBJ) wrote at Wed, 12 Sep 2001 08:46:52 -0700:
MBJ> >[[view delegate] addImage:xxx]; [view reloadData];
MBJ>
MBJ> Actually, this is something I don't understand. My image view registers
MBJ> for notifications from its data source, and the data source sends out
MBJ> notifications when images are added, deleted, or updated, so a call to
MBJ> reloadData is unnecessary. This seems even cleaner to me - or am I
MBJ> missing something that my scheme will miss?

I guess this:

for (i=0;i<MANY;i++) [[view delegate] addImage:xxx];
[view reloadData];

Of course, you can send those notifications using NSPostWhenIdle, which
would easily solve this problem (but not some more elaborated ones).

OTOH, the "automatic display" is a very nice thing generally and I would
keep it; adding a method "addImageWithoutNotification:" or alike would cover
IMHO all needs perfectly.
---
Ondra Cada
OCSoftware: email@hidden http://www.ocs.cz
private email@hidden http://www.ocs.cz/oc


  • Follow-Ups:
    • Re: an interesting delegate design issue raised by IB...
      • From: "Michael B. Johnson" <email@hidden>
References: 
 >Re: an interesting delegate design issue raised by IB... (From: "Michael B. Johnson" <email@hidden>)

  • Prev by Date: Re: Cocoa Open GL help
  • Next by Date: Re: an interesting delegate design issue raised by IB...
  • Previous by thread: Re: an interesting delegate design issue raised by IB...
  • Next by thread: Re: an interesting delegate design issue raised by IB...
  • Index(es):
    • Date
    • Thread