Re: URL Request from AppDelegate?

2012-12-12 Thread Nick Zitzmann
On Dec 12, 2012, at 6:22 PM, berry hunt wrote: > - where in the AppDelegate class would a URL be sent, to somewhere? How do > I track it down? Try breaking on -[NSURLConnection initWithRequest:delegate:] and -[NSURLConnection initWithRequest:delegate:startImmediately:]. The documentation is n

NSView image corruption when dragging from scaled view

2012-12-12 Thread Clay Heaton
I'm trying to implement dragging of a subclass of NSView, to copy an NSImage to the pasteboard so that it can be dragged into other applications (Pages, Mail, etc.). It works as expected until I resize the NSView's parent window (which resizes the NSView -- it always remains square). Once resize

URL Request from AppDelegate?

2012-12-12 Thread berry hunt
Hi gurus, I am pretty new to cocoa development, and would like to ask for help on some questions here that I am struggling with. Any insight will be greatly appreciated. I am trying to establish Facebook login session via my mobile app, but got an error of following message *Error: HTTP status c

Re: iOS: failed to attach drawable storage

2012-12-12 Thread Gerriet M. Denkmann
On 12 Dec 2012, at 20:51, "Gerriet M. Denkmann" wrote: > An iOS app which compiled and build and run in May (probably iOS 5) now > creates the following messages when running in iPhone or iPad Simulator > Version 6.0 (358.4): > > -[AppDelegate application:didFinishLaunchingWithOptions:] star

Re: clarification about document type extensions

2012-12-12 Thread Rick C.
Thank you very much for the replies it's most helpful... On Dec 11, 2012, at 4:50 AM, Charles Srstka wrote: > On Dec 10, 2012, at 11:44 AM, Sean McBride wrote: > >> On Mon, 10 Dec 2012 18:33:00 +0800, Rick C. said: >> >>> Hoping for some clarification here...with a Mac app if I set a bunch o

Re: split views, best practices for 10.8?

2012-12-12 Thread Chuck Soper
Your message helps a lot. Yesterday, I finally got it working. I had been trying to load a custom view with constraints from a nib file into the cell of an NSTableView which was inside an NSSplitView. By isolating the constraints in my custom view, I discovered the errors I was making. That is, I f

Re: blocks and id

2012-12-12 Thread Jens Alfke
On Dec 12, 2012, at 5:24 AM, Andreas Grosam wrote: > And, it can be a block as well, where the block is responsible to feed the > consumer (the id) with data when it has bytes > available when the request is active. > You can do this with the same method, same API. Well, it MUST, otherwise the

Re: blocks and id

2012-12-12 Thread Mike Abdullah
On 12 Dec 2012, at 14:14, Jean Suisse wrote: > On 12 déc. 2012, at 13:02, Mike Abdullah wrote: > >> Why does your code care if some unknown object is a block? This is a strong >> sign of a bad design. > > > As far as I am concerned, I can think of at least two or three legitimate > reasons

Re: NSScrollView's document view resizing?

2012-12-12 Thread Todd Heberlein
On Dec 12, 2012, at 12:11 PM, Kyle Sluder wrote: > There is a workaround, though: instead of dragging out a Scroll View > from the Object Library, drag out a Custom View and choose Editor > > Embed > In Scroll View. Yes, I get two different results depending on how I created a custom view insi

Re: NSScrollView's document view resizing?

2012-12-12 Thread Todd Heberlein
On Dec 12, 2012, at 12:11 PM, Kyle Sluder wrote: > Why not just set the autoresizing mask in IB? I confess, I tried to look for it but could not find it. I don't know if it is there and I just wasn't bright enough to figure it out, or if it simply isn't there. > If it's because your NIB > us

Re: NSScrollView's document view resizing?

2012-12-12 Thread Kyle Sluder
On Wed, Dec 12, 2012, at 11:44 AM, Todd Heberlein wrote: > > On Dec 12, 2012, at 9:31 AM, Kyle Sluder wrote: > > > What's the autoresizing mask on your document view? Even though your > > document view is the subview of a scroll view, it still gets > > -resizeWithOldSuperviewSize: as normal.

Re: NSScrollView's document view resizing?

2012-12-12 Thread Todd Heberlein
On Dec 12, 2012, at 9:31 AM, Kyle Sluder wrote: > What's the autoresizing mask on your document view? Even though your document > view is the subview of a scroll view, it still gets > -resizeWithOldSuperviewSize: as normal. If your autoresizing mask had the > width- or height-sizable bits set

Re: NSScrollView's document view resizing?

2012-12-12 Thread Kyle Sluder
On Dec 12, 2012, at 9:23 AM, Todd Heberlein wrote: > Very basic question: > > When I have an NSScrollView, when I resize the window (which resizes the > NSScrollView), the NSScrollView's documentView (my NSView subclass) gets > resized. > > I didn't expect that to happen. I thought the docume

NSScrollView's document view resizing?

2012-12-12 Thread Todd Heberlein
Very basic question: When I have an NSScrollView, when I resize the window (which resizes the NSScrollView), the NSScrollView's documentView (my NSView subclass) gets resized. I didn't expect that to happen. I thought the documentView's size would remain constant and the scrollbars would chang

Cocoaheads Lake Forest Meets Tonight (really, this time)

2012-12-12 Thread Scott Ellsworth
As promised last week, Stuart Cracraft will be discussing "Massive data mining on a MacBook Air." CocoaHeads Lake Forest will be meeting on the second Wednesday of the month. We will be meeting at the Orange County Public Library (El Toro) community room, 24672 Raymond Way, Lake Forest, CA 92630

Re: blocks and id

2012-12-12 Thread Jean Suisse
On 12 déc. 2012, at 13:02, Mike Abdullah wrote: > Why does your code care if some unknown object is a block? This is a strong > sign of a bad design. As far as I am concerned, I can think of at least two or three legitimate reasons to care wether an unidentified object is a block or not. But

Re: blocks and id

2012-12-12 Thread Mike Abdullah
On 12 Dec 2012, at 13:24, Andreas Grosam wrote: > > On 12.12.2012, at 13:02, Mike Abdullah wrote: > >> >> On 12 Dec 2012, at 09:57, Andreas Grosam wrote: >> >> Why does your code care if some unknown object is a block? This is a strong >> sign of a bad design. > > Oh, then a lot of common C

Re: blocks and id

2012-12-12 Thread Andreas Grosam
On 12.12.2012, at 13:02, Mike Abdullah wrote: > > On 12 Dec 2012, at 09:57, Andreas Grosam wrote: > > Why does your code care if some unknown object is a block? This is a strong > sign of a bad design. Oh, then a lot of common Cocoa patters like dug typing and the usage -respondsToSelector:,

Re: blocks and id

2012-12-12 Thread Mike Abdullah
On 12 Dec 2012, at 09:57, Andreas Grosam wrote: > > On 12.12.2012, at 10:19, Charles Srstka wrote: > >> On Dec 12, 2012, at 3:03 AM, Andreas Grosam wrote: >> >>> How can I check at runtime whether an object (id) is actually a block, and >>> not another kind of object? >> >> I don't think th

Re: blocks and id

2012-12-12 Thread Gwynne Raskind
On Dec 12, 2012, at 6:36 AM, jonat...@mugginsoft.com wrote: > On 12 Dec 2012, at 09:57, Andreas Grosam wrote: >> On 12.12.2012, at 10:19, Charles Srstka wrote: >>> On Dec 12, 2012, at 3:03 AM, Andreas Grosam wrote: >>> How can I check at runtime whether an object (id) is actually a block, a

Re: blocks and id

2012-12-12 Thread Andreas Grosam
On 12.12.2012, at 12:36, jonat...@mugginsoft.com wrote: > You could perhaps make this a little less fragile. > >typedef void (^MyBlockType)(void); > >// we know this is a block >void (^isaBlock)(void) = ^(void) {}; > >MyBlockType aBlock = ^(void) {NSLog(@"I am a block");}; > >

Re: blocks and id

2012-12-12 Thread jonat...@mugginsoft.com
On 12 Dec 2012, at 09:57, Andreas Grosam wrote: > > On 12.12.2012, at 10:19, Charles Srstka wrote: > >> On Dec 12, 2012, at 3:03 AM, Andreas Grosam wrote: >> >>> How can I check at runtime whether an object (id) is actually a block, and >>> not another kind of object? >> >> I don't think t

iOS: failed to attach drawable storage

2012-12-12 Thread Gerriet M. Denkmann
An iOS app which compiled and build and run in May (probably iOS 5) now creates the following messages when running in iPhone or iPad Simulator Version 6.0 (358.4): -[AppDelegate application:didFinishLaunchingWithOptions:] start -[MapViewController viewDidLoad] start -[MapViewCon

Re: blocks and id

2012-12-12 Thread Andreas Grosam
On 12.12.2012, at 10:19, Charles Srstka wrote: > On Dec 12, 2012, at 3:03 AM, Andreas Grosam wrote: > >> How can I check at runtime whether an object (id) is actually a block, and >> not another kind of object? > > I don't think there's any good way of doing that right now. You could check >

Re: blocks and id

2012-12-12 Thread Charles Srstka
On Dec 12, 2012, at 3:03 AM, Andreas Grosam wrote: > How can I check at runtime whether an object (id) is actually a block, and > not another kind of object? I don't think there's any good way of doing that right now. You could check the class of the block, but since the block classes are comp

blocks and id

2012-12-12 Thread Andreas Grosam
How can I check at runtime whether an object (id) is actually a block, and not another kind of object? Andreas ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the