• 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
Re: Using runtime functions to match up object types safely when setting properties
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using runtime functions to match up object types safely when setting properties


  • Subject: Re: Using runtime functions to match up object types safely when setting properties
  • From: Graham Cox <email@hidden>
  • Date: Sun, 21 Dec 2008 10:37:37 +1100


On 21 Dec 2008, at 4:07 am, Michael Ash wrote:

You could build a table, either manually or perhaps with the help of
some sort of crazy macro. But there is absolutely no way to get the
NSColor out of -(void)setColor:(NSColor*)c at runtime because that
info simply isn't there.


Yep, I've come to understand that.

It looks as if I'll have to extend the scheme where my objects publish the properties that are exposed in the UI to also include acceptable type information, so the UI has something to go on when disabling improper combinations. A bit of a pain but not all that unreasonable.

thanks everyone for helping out,

cheers, Graham




_______________________________________________

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


References: 
 >Using runtime functions to match up object types safely when setting properties (From: Graham Cox <email@hidden>)
 >Re: Using runtime functions to match up object types safely when setting properties (From: Ken Thomases <email@hidden>)
 >Re: Using runtime functions to match up object types safely when setting properties (From: Andrew Farmer <email@hidden>)
 >Re: Using runtime functions to match up object types safely when setting properties (From: Graham Cox <email@hidden>)
 >Re: Using runtime functions to match up object types safely when setting properties (From: "Michael Ash" <email@hidden>)

  • Prev by Date: Re: toolbar to view gradient displaying correctly only sometimes?
  • Next by Date: Re: selectionShouldChangeInTableView called twice
  • Previous by thread: Re: Using runtime functions to match up object types safely when setting properties
  • Next by thread: Re: Using runtime functions to match up object types safely when setting properties
  • Index(es):
    • Date
    • Thread