开发者

Change "Controller Key" list for bindings in IB Inspector

开发者 https://www.devze.com 2023-01-14 08:55 出处:网络
I have next question: I create own Controller ( myController:NSObjectController ) and it has own attributes, for example NSSt开发者_如何转开发ring* title;

I have next question:

I create own Controller ( myController:NSObjectController ) and it has own attributes, for example NSSt开发者_如何转开发ring* title;

Now I want to bind this attribute to some text field. Can I made that attribute 'title' display in 'Controller Key' menu of inspector binding window in IB; (There where 'selection', 'canADD' and else)

Dont worry about access to this attribute, I want just add it in to list


I think what you want to do is to:

  • drag an NSObjectController from the Library palette
  • connect its "content" outlet to the instance of your NSObject
  • add "title" to the NSObjectController's list of "Keys"
  • then use the "title" attribute of your NSObjectController in your text field bindings

I hope this helps.

0

精彩评论

暂无评论...
验证码 换一张
取 消