On Tue, May 6, 2008 at 12:46 AM, Karl von Moller <[EMAIL PROTECTED]> wrote: > Many thanks for your reply on this - much appreciated. I did think it had > something to do with the images being swapped out as often the crashes > occurred as I quickly changed selection in the table view. Because I know > nothing about threading, I resorted to anything to lock the threads. That's > why you see my silly attempt at Locking!
I mean no offense by any of this, but threading is a really complex and difficult subject that you can't really just jump into and try to get something working by trial and error. Partly this is because it's difficult to the extent that you can't reasonably learn it by trial and error. Partly this is because threading bugs are often extremely subtle and it's entirely reasonable to write code which works fine for you now but which breaks in extremely difficult to debug ways later on. There are lots of articles out there on general problems in multithreading, locks, synchronization, message passing, and such. For Apple-specific documentation, I'd recommend: Threaded Programming Guide: http://developer.apple.com/documentation/Cocoa/Conceptual/Multithreading/Introduction/chapter_1_section_1.html Cocoa Fundamentals Guide: Multithreaded Cocoa Programs: http://developer.apple.com/documentation/Cocoa/Conceptual/CocoaFundamentals/AddingBehaviortoaCocoaProgram/chapter_4_section_6.html This is part of the first article but it's really important so I'm including it separately, Cocoa thread safety guidelines: http://developer.apple.com/documentation/Cocoa/Conceptual/Multithreading/ThreadSafetySummary/chapter_950_section_2.html# I highly encourage reading through all of those and any other resources you can lay hands on. Your current path will at best result in a program which works *most* of the time. Mike _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]