Re: Cannot encode custom NSView
Re: Cannot encode custom NSView
- Subject: Re: Cannot encode custom NSView
- From: Ricky Sharp <email@hidden>
- Date: Tue, 09 Nov 2004 08:19:39 -0600
On Tuesday, November 09, 2004, at 07:28AM, Ricky Sharp <email@hidden> wrote:
>What's really interesting is that I've successfully built another IB palette around my IIButton/IIButtonCell objects. Such objects successfully encode/decode several color objects. I'm under the impression that I'm missing something painfully obvious and I keep making the same mistakes even when starting fresh.
>
>The only other difference is that this is an object that inherits from NSView and not NSControl/NSCell (as does IIButton/IIButtonCell). But that shouldn't make any difference as what I have coded should adhere to both the NSCoding and NSCopying protocols.
I started a fresh project where my IIGraphic object is now an NSControl/NSCell combo and all works well (color iVar works as expected). Thus, it's either something I'm doing wrong in the subclassed NSView approach, or such a thing is not possible to do.
I don't have a problem in having all my custom widgets inherit from NSControl/NSCell. Some of my widgets really didn't need that extra complexity, so that's why I started out with the NSView approach.
--
Rick Sharp
Instant Interactive(tm)
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden