Hi everyone,

I have an NSPredicateEditor, with some standard row templates.  I'd like to add 
a custom row template with three views:  a popup button (indicating the 
attributes this template references), a second popup button (with the 
operators), and a third popup button that's populated with a list of possible 
values.

This is very similar to a regular row template, except that the list of 
possible values is computed at runtime and can change periodically based on 
system events.

I've tried subclassing NSPredicateEditorRowTemplate, overriding -templateViews, 
and returning my 3 popup buttons (all properly populated).  This works once, 
but after the row is created, I haven't been able to figure out how to 
repopulate the popup button when the list of possible values changes.  I've 
tried setting the popup button's menu's delegate to an object that will 
repopulate it, but the delegate methods are never called.

I've also seen that when there's only one possible value, my popup button is 
replaced with a textfield.  I suppose that's OK, except that if the list of 
possible values changes, I need that textfield to change to a popup button.

How can I achieve my dynamic popup button in an NSPredicateEditorRowTemplate?

Thanks!

Dave DeLong

Attachment: smime.p7s
Description: S/MIME cryptographic signature

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to