Skip to content

Commit

Permalink
Merge pull request #243 from BigRoy/bugfix/support_deleting_workfile_…
Browse files Browse the repository at this point in the history
…instance

Support deleting workfile instances
  • Loading branch information
BigRoy authored Feb 28, 2025
2 parents 8d6d9c7 + 61d4b3d commit 42c8515
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions client/ayon_maya/api/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -278,6 +278,7 @@ def _default_update_instances(self, update_list):

self.imprint_instance_node(node, data)

@lib.undo_chunk()
def _default_remove_instances(self, instances):
"""Remove specified instance from the scene.
Expand Down
3 changes: 3 additions & 0 deletions client/ayon_maya/plugins/create/create_workfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,9 @@ def collect_instances(self):
created_instance = CreatedInstance.from_existing(node_data, self)
self._add_instance_to_context(created_instance)

def remove_instances(self, instances):
self._default_remove_instances(instances)

def update_instances(self, update_list):
for created_inst, _changes in update_list:
data = created_inst.data_to_store()
Expand Down

0 comments on commit 42c8515

Please sign in to comment.