Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MAYA-108770 - When an Xformable is added to a USD Prim, the Attribute… #1233

Merged
merged 1 commit into from
Mar 5, 2021

Conversation

spinell-adsk
Copy link
Contributor

… Editor doesn't update automatically

-Fix AE refresh issue when transform changed on a prim

… Editor doesn't update automatically

-Fix AE refresh issue when transform changed on a prim
@spinell-adsk spinell-adsk requested a review from seando-adsk March 4, 2021 00:58
@spinell-adsk
Copy link
Contributor Author

Add a custom widget with no UI into the UFE attribute editor template.
The custom widget is a UFE attribute observer used to refresh the AE when the prim transform changed.

@spinell-adsk spinell-adsk requested a review from ppt-adsk March 4, 2021 01:04
Copy link
Collaborator

@seando-adsk seando-adsk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me.

@seando-adsk seando-adsk added adsk Related to Autodesk plugin core Related to core library ready-for-merge Development process is finished, PR is ready for merge and removed adsk Related to Autodesk plugin labels Mar 4, 2021
@seando-adsk
Copy link
Collaborator

@spinell-adsk / @kxl-adsk - I marked this as ready for merge. The only change is to the attribute editor template file which is not used in any test, so I see no need to run a preflight.

super(UfeAttributesObserver, self).__init__()
self._item = item

def __del__(self):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is nothing wrong with this, but it's not needed, strictly speaking. The Subject keeps a weak ptr to its observers, and cleans up dead weak ptrs on notification, so that when an observer dies, the Subject will not notify it, and will end up removing it.

As a matter of fact, simply to avoid future developers copy-pasting this code, we should just remove it.

@kxl-adsk kxl-adsk merged commit d1fe7cd into dev Mar 5, 2021
@kxl-adsk kxl-adsk deleted the spinell/MAYA-108770/ae_transform_refresh branch March 5, 2021 11:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Related to core library ready-for-merge Development process is finished, PR is ready for merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants