Re: Simple question driving me CRAZY
Re: Simple question driving me CRAZY
- Subject: Re: Simple question driving me CRAZY
- From: Dave DeLong <email@hidden>
- Date: Sat, 16 Jun 2012 14:13:03 -0700
From http://developer.apple.com/library/mac/releasenotes/ObjectiveC/RN-TransitioningToARC/Introduction/Introduction.html#//apple_ref/doc/uid/TP40011226-CH1-SW17:
> Which classes don’t support weak references?
> You cannot currently create weak references to instances of the following classes:
> NSATSTypesetter, NSColorSpace, NSFont, NSFontManager, NSFontPanel, NSImage, NSMenuView, NSParagraphStyle, NSSimpleHorizontalTypesetter, NSTableCellView,NSTextView, NSViewController, NSWindow, and NSWindowController. In addition, in OS X no classes in the AV Foundation framework support weak references.
> For declared properties, you should use assign instead of weak; for variables you should use __unsafe_unretained instead of __weak.
> In addition, you cannot create weak references from instances of NSHashTable, NSMapTable, or NSPointerArray under ARC.
HTH,
Dave
On Jun 16, 2012, at 2:06 PM, Brad Stone wrote:
> I have a subclass of a NSViewController. In fact, I created on just as a test with no custom code. I then throw an NSTextView in the NSView that comes with it and then drag from the NSTextView to the .h file to create an outlet. Why why why is it making it unsafe_unretained? I'm using ARC. Why it's it weak like every other subview? The NSTextView is in a NSScrollView which is in the controllers NSView. The NSScrollView is coming in as weak.
>
>
> It's been diving me insane all day.
>
> Thanks
> _______________________________________________
>
> Cocoa-dev mailing list (email@hidden)
>
> Please do not post admin requests or moderator comments to the list.
> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden