Tk-multi-publish2 custom widget settings based on publish item

Hello Shotgunners!

I have added a custom widget (combobox) to a publish plugin in the publisher, and would like to set my combobox to a value based on the item. Is it possible to talk to my widget from the accept method or so?

Basically I want to look at the items path and change the combobox current item based on what I can find in the path.


1 Like

Hi Jonas! I’m gonna run this by an engineer, but off the top of my head, I think the answer, sadly, is no.

It looks like the create_settings_widget() method, which is what you use to add custom UI, doesn’t take anything but the parent widget, so I don’t see how you could pass it the return value from accept(). It’s a good request though – I’ll see if I can get more info for you.


Hi Jonas –

Just wanted to follow up on this one. I had a hunch that you might be able to do this by populating self.items and then referring to that attribute inside set_ui_widgets() , but I ran it by an engineer, and it sounds like that won’t work:

Unfortunately you don’t have access to the item object during create_settings_widget, get_ui_settings and set_ui_settings, so it’s not possible to know how the settings you are displaying relate to other settings on other items in the scene and what items are child of the currently selected one.

In order to do this, we need to augment these UI methods to also pass in the PublishItem. I’ve shared that request with the product team.


Hi Tannaz,

Thanks for looking in to this. It’s not something I can’t live without, more of a nice-to-have feature.