pyblish / pyblish-qml

Pyblish QML frontend for Maya 2013+, Houdini 11+, Nuke 8+ and more
GNU Lesser General Public License v3.0
114 stars 44 forks source link

Implementing #315 #316

Closed davidlatwe closed 5 years ago

davidlatwe commented 5 years ago

The implementation of #315, which aim to keep the GUI to display the latest status data change of instances, like optional, publish, families.

Currently, once the plugin which responsible to create the instance, has been processed, the change of the instance data that made by other plugins will not reflected to GUI. For example, the newly added family will not be shown in Perspective View, and setting publish to False will not toggle instance off.

Not good to merge yet.

davidlatwe commented 5 years ago

I have completed the implementation of GUI's instance status update and instance removal, this will make pyblish-qml's primary iterator behaves like pyblish-base's.

Which means plugins could change instance's family, publish status data or removing instance from context, and affect the publish flow in run-time with GUI.

Implementations

There are two kinds of instances in pyblish-qml's GUI process, instance model item used by GUI for displaying, and proxy instances that are being iterated in the primary iterator. And they all get updated by the cached instances which parsed from host at each iteration, but with slightly difference.

For presenting correct info on GUI, instance model item needs to update these attributes:

For iterating instances correctly with GUI's iterator, the instance proxy needs to update these data entries:

And the primary iterator will skip the instance that has been marked as removed or the publish flag has been switched off.


I think it's good to be reviewed now, please let me know what you think about this enhancement.

Thanks !

asztalosdani commented 5 years ago

Hi,

we have a few plugins that update the families and publish flags, so it would be good to see this merged. :)

mottosso commented 5 years ago

Happy to merge this, @davidlatwe when you're happy I'm happy!

davidlatwe commented 5 years ago

Thanks! Have been running this in production for a while here, I’ll take a look at this again and merge this later if all okay !

davidlatwe commented 5 years ago

I have pushed two more commits that was only in my local production branch, one is an improvement on instance removal (d50e7e9), and the other (3082f8a) was for debugging (Sorry for mixing this one here).

Please let me know if there's any problem :)

davidlatwe commented 5 years ago

Merging this :)