Make sure your main thread is not busy, stuck waiting in a lock, or in a modal
loop. If it is many outside messages to the main thread and most UI updating
will be queued up until the main thread is free again.
If this is the case, then it's not surprising NSProgressIndicator updates as it
is
Interestingly, I also have a progressbar, and that one gets updated as expected
in all cases. Very strange.
- Koen.
On Oct 14, 2012, at 4:54 PM, Koen van der Drift
wrote:
>
> On Oct 14, 2012, at 4:47 PM, Mike Abdullah wrote:
>
>> Presumably statisTextField is an outlet? Sure you've got it
On Oct 14, 2012, at 4:47 PM, Mike Abdullah wrote:
> Presumably statisTextField is an outlet? Sure you've got it hooked up right?
Yup, it is an outlet and hooked up. SInce it is being updated during the
download phase of the process, I can assume it is connected correctly.
- Koen.
On 14 Oct 2012, at 20:29, Koen van der Drift wrote:
>
> On Oct 14, 2012, at 3:04 PM, Mike Abdullah wrote:
>
>> How did you determine that -updateStatusWrapper: doesn't get called?
>>
>> (You could do away with that method entirely BTW, and just use
>> setProgressStatus: as the selector)
>>
On Oct 14, 2012, at 4:34 PM, Kyle Sluder wrote:
> Okay, at this point you need to step back a bit and actually work
> through your threading architecture. The first question to ask yourself
> is whether you actually understand multithreading. The second question
> to ask is whether you actually
On Sun, Oct 14, 2012, at 12:29 PM, Koen van der Drift wrote:
> Even if I use:
>
> - (void)updateStatus: (NSString *)status
> {
> [statusTextField performSelectorOnMainThread:@selector(
> setStringValue:) withObject: status waitUntilDone: NO]; // or YES
> }
>
> the field does not get upda
On Oct 14, 2012, at 3:04 PM, Mike Abdullah wrote:
> How did you determine that -updateStatusWrapper: doesn't get called?
>
> (You could do away with that method entirely BTW, and just use
> setProgressStatus: as the selector)
>
> You're updating a property of self. How does that then update t
On 12 Oct 2012, at 23:55, Koen van der Drift wrote:
>
> Man, I thought I had this all working, and after a few days of doing other
> stuff, it is back to my original issue. I am now updating my textfield as
> follows, so no matter from where it is called, it will always be updated on
> the
Man, I thought I had this all working, and after a few days of doing other
stuff, it is back to my original issue. I am now updating my textfield as
follows, so no matter from where it is called, it will always be updated on the
main thread:
- (void)updateStatus: (NSString *)status
{
NSLo
On Oct 1, 2012, at 6:31 PM, Mike Abdullah wrote:
> Yes, you don't understand the consequences of your code yet. AppKit is not
> threadsafe. You absolutely MUST only update UI on the main thread for
> something like this.
>
> Make sure your -parseData routine is threadsafe, and then bounce bac
On 1 Oct 2012, at 22:39, Koen van der Drift wrote:
>
> On Oct 1, 2012, at 8:59 AM, Koen van der Drift
> wrote:
>
>> Ok, I decided to use NSOperation(Queue) as it is generally recommended
>> over performSelectorXXX to be a more modern API, and have been reading
>> a bit about it. In Hillegas
On Oct 1, 2012, at 5:39 PM, Koen van der Drift
wrote:
>[myQueue addOperationWithBlock:^(void)
>{
>[self parseData]; // calculate the new data and update the model
> }];
>
> // now tell everyone we're done
>[self finishedTask]; // update the NSTableV
On Oct 1, 2012, at 8:59 AM, Koen van der Drift
wrote:
> Ok, I decided to use NSOperation(Queue) as it is generally recommended
> over performSelectorXXX to be a more modern API, and have been reading
> a bit about it. In Hillegass' Cocoa book, he uses processQueue
> addOperationWithBlock, in o
On Sun, Sep 30, 2012 at 7:20 PM, Koen van der Drift
wrote:
>
> On Sep 30, 2012, at 6:51 PM, Ken Thomases wrote:
>
>> Move the long-running operation to a background thread (e.g. using
>> -performSelectorInBackground:withObject:, or dispatch_async() to a non-main
>> queue, or NSOperation and NSO
On Sep 30, 2012, at 6:51 PM, Ken Thomases wrote:
> Move the long-running operation to a background thread (e.g. using
> -performSelectorInBackground:withObject:, or dispatch_async() to a non-main
> queue, or NSOperation and NSOperationQueue, etc.). However, all updates to
> the GUI still hav
On Sep 30, 2012, at 5:26 PM, Koen van der Drift wrote:
> I am downloading and parsing a large file from a database, and to keep the
> user informed, I have a NSTextField where I display the status. The field is
> bound to an NSString (progressStatus), and the controller has the following
> meth
I am downloading and parsing a large file from a database, and to keep the user
informed, I have a NSTextField where I display the status. The field is bound
to an NSString (progressStatus), and the controller has the following method to
update it:
-(void)updateStatus: (NSString *) status
{
17 matches
Mail list logo