Swift and NSXPCInterface

2014-08-08 Thread Gerriet M. Denkmann
I am trying to translate this: NSXPCInterface *b = [NSXPCInterface interfaceWithProtocol:@protocol(Xpc_CommonProtocol)]; to Swift. This compiles (and runs) as expected: var dummy : AnyObject? if let protoDummi = dummy as? Xpc_CommonProtocol { println("dummy DOES implement Xpc_Co

Re: NSProgressIndicator (bar) still displays when stopped

2014-08-08 Thread Daryle Walker
On Aug 8, 2014, at 12:55 PM, Keary Suska wrote: > On Aug 8, 2014, at 10:25 AM, Daryle Walker wrote: > >> On Aug 8, 2014, at 9:58 AM, Keary Suska wrote: >> >>> Is the progress indicator loaded from a xib, with your initial settings? If >>> so I would double-check the isDisplayedWhenStopped va

Re: NSProgressIndicator (bar) still displays when stopped

2014-08-08 Thread Keary Suska
On Aug 8, 2014, at 10:25 AM, Daryle Walker wrote: > On Aug 8, 2014, at 9:58 AM, Keary Suska wrote: > >> On Aug 7, 2014, at 10:23 PM, Daryle Walker wrote: >> >>> have a bar-style NSProgressIndicator that has its “Display When Stopped” >>> turned off and (initially) Indeterminate turned on.

Re: NSProgressIndicator (bar) still displays when stopped

2014-08-08 Thread Daryle Walker
On Aug 8, 2014, at 9:58 AM, Keary Suska wrote: > On Aug 7, 2014, at 10:23 PM, Daryle Walker wrote: > >> have a bar-style NSProgressIndicator that has its “Display When Stopped” >> turned off and (initially) Indeterminate turned on. It (almost) properly >> updates when a load is going on: >>

Re: NSProgressIndicator (bar) still displays when stopped

2014-08-08 Thread Jerry Krinock
On 2014 Aug 08, at 06:58, Keary Suska wrote: > IIRC there has been a long-standing bug with NSProgressIndicator in certain > views. Try calling [[self.loadingProgress superview] setNeedsDisplay:YES] > after you stop animation. If that works, that will be confirmation that the > bug still stan

Re: NSProgressIndicator (bar) still displays when stopped

2014-08-08 Thread Keary Suska
On Aug 7, 2014, at 10:23 PM, Daryle Walker wrote: > have a bar-style NSProgressIndicator that has its “Display When Stopped” > turned off and (initially) Indeterminate turned on. It (almost) properly > updates when a load is going on: > > //= > - (void)notifyOnProgressStarted:(NSNotifica

Re: unapprehended about block in code

2014-08-08 Thread User Mac
yeah,I understand the reason of code. Thanks very much! bigpig 在 2014年8月8日,15:58,Viacheslav Karamov 写道: > "completion" is a block with return type void which has a parameter of type > BOOL. > A user could pass nil instead of block, so we need to check if block is > supplied before invoke it.

Re: unapprehended about block in code

2014-08-08 Thread Viacheslav Karamov
"completion" is a block with return type void which has a parameter of type BOOL. A user could pass nil instead of block, so we need to check if block is supplied before invoke it. 08.08.14 10:45, User Mac wrote: - (void)dismissAnimated:(BOOL)animated completion:(void(^)(BOOL finished))comple

unapprehended about block in code

2014-08-08 Thread User Mac
- (void)dismissAnimated:(BOOL)animated completion:(void(^)(BOOL finished))completion { void(^completionBlock)(BOOL) = ^(BOOL finished){ [self somefunction]; if(completion) { completion(finished);