On Sep 19, 2015, at 20:09 , Alex Hall <[email protected]> wrote:
>
> [_NSControllerObjectProxy copyWithZone:]: unrecognized selector sent to
> instance 0x608000000ae0
>
> failed to set (contentViewController) user defined inspected property on
> (NSWindow): -[_NSControllerObjectProxy copyWithZone:]: unrecognized selector
> sent to instance 0x608000000ae0
I dunno, the things mentioned in the message don’t really go together.
“contentViewController” is a property of a NSWindowController, not a NSWindow,
and its value ought to be a NSViewController, not anything related to a
NSController (which is something entirely different, in spite of the similar
name).
This could be a memory management error (the original object has been
deallocated, and the memory re-used for another object), an invalid connection
in the storyboard, or just a misleading message. Or any combination of those.
> Failed to connect (tweetTextField) outlet from (Cinnamon.ViewController) to
> (NSTextView): missing setter or instance variable
> @IBOutlet weak var tweetScrollView:NSScrollView!
> var tweetTextField:NSTextView { //all we need here is the text view
> inside the scroll view
> get {
> return tweetScrollView.contentView.documentView as!
> NSTextView
> }
> }
It kinda looks like you once had tweetTextField set up as an outlet, then
changed it to a normal property. If it was actually connected in the storyboard
when you changed it, IB would remember the name, and that it used to represent
an outlet. (IB tries not to throw away connections you previously made, in case
they’re only temporarily missing from the source.) This is harmless if the
source property is really gone, but I’d guess that IB sees it’s come back
again, and is therefore trying to make the connection at run time — and of
course it can’t without a setter or a non-computed property.
The solution would be to find the connection in the IB inspector and manually
disconnect it. At that point, the outlet should disappear from IB completely.
Incidentally, this would be another bug to report, possibly two. The first bug
is that IB didn’t realize it’s not really an outlet any more. The second is
that IB marks invalid outlets with a little exclamation point icon, and I
suspect this is very hard or impossible to detect via VO. (Even if the
accessibility information tells you that it’s so marked, you’d have to check
each outlet individually to find out. If you can see the inspector, a single
glance tells you if there are any invalid outlets.)
_______________________________________________
Cocoa-dev mailing list ([email protected])
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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com
This email sent to [email protected]