Simplify.
This commit is contained in:
@@ -68,10 +68,7 @@ void SetCocoaWindowText(const char *s)
|
|||||||
{
|
{
|
||||||
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
|
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
|
||||||
NSString *str = [NSString stringWithUTF8String:s];
|
NSString *str = [NSString stringWithUTF8String:s];
|
||||||
|
[text performSelectorOnMainThread:@selector(setString:) withObject:(str ? str : @"") waitUntilDone:NO];
|
||||||
[text setString:( str ? str : @"" )];
|
|
||||||
[text performSelectorOnMainThread:@selector(setNeedsDisplay:) withObject:[NSNumber numberWithBool:YES]
|
|
||||||
waitUntilDone:NO];
|
|
||||||
[pool release];
|
[pool release];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user