• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Subclassed control in IB uses original cell class
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Subclassed control in IB uses original cell class


  • Subject: Subclassed control in IB uses original cell class
  • From: David Hoerl <email@hidden>
  • Date: Wed, 28 Nov 2007 15:48:03 -0500

I found a neat double knobbed slider on the web: http://developer.snowmintcs.com/controls/smdoubleslider/

There is only a IB2 palette, so I figured I'd just add a NSSlider object to my NIB, change its class to SMDoubleClass, then do anything further in awakeFromNib.

The problem is that the control ends up with a NSSliderCell and not a SMDoubleSliderCell - guess +cellClass does not get invoked for archived objects.

At first, I could not subclass the cell as a nib2.x file does not support it. However, the IB3 docs say I can use the nib3.x file on Tiger (for building only, not editing). So, I changed formats, changed the cell class, and now all is working as expected.

I was wondering though - suppose I had to stay with IB2 - how would I get the correct class of cell?

David
_______________________________________________

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


  • Follow-Ups:
    • Re: Subclassed control in IB uses original cell class
      • From: Corbin Dunn <email@hidden>
    • Re: Subclassed control in IB uses original cell class
      • From: "Sean McBride" <email@hidden>
  • Prev by Date: Re: Sheet Doesn't Attach Itself To Window
  • Next by Date: Re: Sheet Doesn't Attach Itself To Window
  • Previous by thread: Crash drawing a textfield?
  • Next by thread: Re: Subclassed control in IB uses original cell class
  • Index(es):
    • Date
    • Thread