Im looking through Presence3, understand the LetsMakeAThread project, its pretty straight forward, detachNewThread creates a separate thread and performSelectorOnMainThread returns you to the MT, but in ThreadedFlickrTableView, whats the deal? beginLoadingFlickrData calls a new invocation operation, which loads synchronousLoadFlickrData: which gets the data from Flickr and returns to MT via didFinishLoadingFlickrDataWithResults: which in turn creates the arrays from the FlickrData. Then cachedImageForURL gets called from the cellForRowAtIndexPath? And so that same method calls the ImageLoadingOperation which then returns to the main thread via didFinishLoadingImageWithResult:? Is this chronology correct? The MT gets separated or stopped 2x in this app? Once in beginLoadingFlickrData and then in cachedImageForURL? The difference being that in… Read More
Continue ReadingMemory Management Stanford CS193P iPhone Dev
Im not so clear on memory management; i understand what you create you must release, ok, but when?! Because i just saw the MyTabBar example which creates ViewControllers, 3 of them i think, programatically, and a few lines down in the same m file, the delegate, the controllers get released. Release means they get destroyed right? I guess im not understanding conceptually what actually happens because to me, if you create in line 10 and release in line 20, even saying it sounds stupid to me, but its what i see, the user wont have time to use it :). Or is it because they get created, then added to… Read More
Continue Reading