From e00cc40b8e58e2e1dca858f1be4ff2040b363548 Mon Sep 17 00:00:00 2001 From: Eric Mehl Date: Wed, 15 Nov 2023 16:45:08 -0500 Subject: [PATCH] fixup! SceneViewUI : Add "Send to Catalog" context menu --- python/GafferSceneUI/SceneViewUI.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/python/GafferSceneUI/SceneViewUI.py b/python/GafferSceneUI/SceneViewUI.py index c454b220758..142c021dd49 100644 --- a/python/GafferSceneUI/SceneViewUI.py +++ b/python/GafferSceneUI/SceneViewUI.py @@ -1136,7 +1136,7 @@ def __snapshotCataloguesSubMenu( view, scriptNode ) : ) else : - snapshotDescription = __snapshotDescription( view ) + commonDescription = __snapshotDescription( view ) commonActive = view["renderer"]["name"].getValue() != "OpenGL" for c in catalogueList : @@ -1149,6 +1149,13 @@ def __snapshotCataloguesSubMenu( view, scriptNode ) : not Gaffer.MetadataAlgo.readOnly( c["images"].source() ) and not Gaffer.MetadataAlgo.readOnly( c["imageIndex"].source() ) ) + + snapshotDescription = commonDescription + if Gaffer.MetadataAlgo.readOnly( c["images"].source() ) : + snapshotDescription = "\"images\" plug is read-only" + if Gaffer.MetadataAlgo.readOnly( c["imageIndex"].source() ) : + snapshotDescription = "\"imageIndex\" plug is read-only" + menuDefinition.append( "/" + ( nName + ( " ({})".format( cName ) if cName else "" ) ), {