Re: RESTful API's - Easy way to interact?

2008-05-31 Thread Peter Burtis
On May 31, 2008, at 1:12 PM, Jens Alfke wrote: I think there's a need for some additional API on NSURLConnection to provide finer-grained control over authentication. In particular, (1) Ability to set credentials on the request before starting the connection (2) Ability to disable the connect

Re: RESTful API's - Easy way to interact?

2008-05-31 Thread Peter Burtis
Question: Is there a way to set the credentials before you initiate the request? Or a way to force the request to use credentials even if the site doesn't return an Authentication Required response? I can't find one. And because of this I've ended up rolling my own Authentication scheme

Re: warning: 'NSEntityDescription' may not respond to

2008-05-30 Thread Peter Burtis
The compiler only knows about methods declared somewhere or the headers, and Core Data accessor methods are handled at runtime and not declared anywhere. It's only a warning and not an error because the compiler is smart enough to know that Objective C can do cool stuff like that. One so

Re: Which framework for Wifi?

2008-05-28 Thread Peter Burtis
On May 27, 2008, at 11:28 PM, J. Scott Tury wrote: And in 10.5.2 the -x command line option does not work at all Hrm... That's odd and disturbing. But not *quite* true. :) I'm using 'airport -x -s' in my little network jumper app to list networks in range, which--I just checked--*does* stil

Re: Which framework for Wifi?

2008-05-27 Thread Peter Burtis
There is a private command line utility at the path: /System/Library/PrivateFrameworks/Apple80211.framework/Versions/ Current/Resources/airport Calling it with NSTask works. If there's a better way I'd love to know it. It will give XML output with the right flag (-x) so it's quite useab

Re: How to Delay, Wait, Pause...

2008-05-24 Thread Peter Burtis
NSThread has a sleepUntilDate: class method. In the example below, 0.1 = 1/10th of a second. NSDate *future = [NSDate dateWithTimeIntervalSinceNow: 0.1 ]; [NSThread sleepUntilDate:future]; -Pete On May 25, 2008, at 2:45 AM, Steve Steinitz wrote: Hello, This is hard to googl

Re: to launch safari with an URL

2008-05-24 Thread Peter Burtis
NSURL *url = [NSURL URLWithString:@"http://www.google.com";]; [[NSWorkspace sharedWorkspace] openURL:url]; -Pete On May 25, 2008, at 12:55 AM, Nick Rogers wrote: Hi, How can I launch the default browser supplying it a URL with the click of a button? Please help. WIshes, Nick _

Re: NSWindow CoreAnimation Delegate not being called

2008-05-24 Thread Peter Burtis
yes, creating a new CAAnimation and then adding it to the window instead of relying on the animation that the window returns seems to solve the problem. -Pete On May 25, 2008, at 12:11 AM, Peter Burtis wrote: I'm no core animation expert, but. This... // sel

Re: NSWindow CoreAnimation Delegate not being called

2008-05-24 Thread Peter Burtis
I'm no core animation expert, but. This... // self is an NSWindow instance CAAnimation *anim = [CABasicAnimation animation]; [anim setDelegate:self]; [self setAnimations:[NSDictionary dictionaryWithObject:anim forKey:@"frame"]]; [[self animator] setFra

Re: Handling keyDown events results in beeping from a NSView subclass...

2008-05-24 Thread Peter Burtis
Add the method -(BOOL)acceptsFirstResponder { return YES; } in the custom and it will work as desired. By default, just clicking on an custom NSView *doesn't* make it the first responder, and keyboard events are sent to the first responder and then up the responder chain, unlike mouse even

Re: NSTextField will not become editable in a borderless window

2008-05-22 Thread Peter Burtis
I've dug through a mountain of code but can't find where I used it. Someone else may remember this trick and help me out... of course, it's not a great solution but it works from 10.3 through 10.5 so far... G. On 22 May 2008, at 10:13 pm, Peter Burtis wrote: When I add an

NSTextField will not become editable in a borderless window

2008-05-22 Thread Peter Burtis
other, better way to create a completely custom window? I'm running 10.5.2, if that matters. Thanks, Peter Burtis ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact th