UIView/NSView doesn't display changing data in real time
UIView/NSView doesn't display changing data in real time
- Subject: UIView/NSView doesn't display changing data in real time
- From: "Frederick C. Lee" <email@hidden>
- Date: Tue, 19 Apr 2011 10:51:48 -0700
Greetings:
Simple scenario: background thread is computing data to be displayed in real time within the main thread.
Data: dynamic/variable data that is converted into a NSString type within a background thread, displayed within a UILabel (or NSLabel) on the main thread.
My own environment: iOS 4+ (relevant to OS X as well) using Xcode 4+.
Design: background thread (via NSOperation/NSOperationQueue) sends data/iteration to the main (host) thread via DELEGATION.
Note: the main thread *** sees **** this data in read time (via NSLog() stmt )....
However, the front end UIView (or NSView) does NOT update/iteration in real time.
Paradigm Request: a real-time digital clock.... tick, tick... you see the seconds being updated. I need to ditto that with velocity, position, etc.
I tried the 'setNeedsDisplay' method call; has no effect.
Question: What is the preferred way to display within the MAIN thread in real time, data that is computed on a back-end thread?
Regards,
Ric._______________________________________________
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