EMSUSD-2536 USD Animation Options are lost when deselected and collapsed - #4694
Conversation
pierrebai-adsk
left a comment
There was a problem hiding this comment.
Suggestion how to fix it differently.
Although, IDK why we were hiding all the UI...
| int $collapse = stringArrayContains("animation", $collapsedSections) ? true : false; | ||
| frameLayout -label `getMayaUsdString("kExportFrameAnimationLbl")` -collapsable true -collapse $collapse | ||
| -expandCommand("mayaUsdTranslatorExport_AnimationFrameLayoutExpandCB") animationFrameLayout; | ||
| frameLayout -label `getMayaUsdString("kExportFrameAnimationLbl")` -collapsable true -collapse $collapse animationFrameLayout; |
There was a problem hiding this comment.
Looking at the behavior I think another way to fix would be to set the visibility of the column layout when toggling the checkbox?
IOW, have a -changeCommand on the animationCheckBox that would call the mayaUsdTranslatorExport_AnimationFrameLayoutExpandCB
There was a problem hiding this comment.
Also, call tha CB when initially creating / filling the UI with values. IDK if when setting value if the CB gets called. Just test it by hand in Maya once the changes are done, maybe you don't need to explicitly call the CB when filling the values, maybe the CB is also called then, but I'm not sure.
There was a problem hiding this comment.
Actually, there is already a CB for the check-box. Just need to toggle visibility too in that CB. (mayaUsdTranslatorExport_AnimationCB)
There was a problem hiding this comment.
...but honestly, liek I initally said, IDK why we were hiding the UI?
There was a problem hiding this comment.
We're not doing that for materials, and other sections. 🤷
pierrebai-adsk
left a comment
There was a problem hiding this comment.
I decied that removing the weird behavior is probably right!
Fix a visual bug when disabling the animation options.