-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
There appears to be no reason not to allow saving a muted layer. It was most likely not allowed due to the implementation, which sets the layer's _data to an empty data object while muted. If we saved that we'd get an empty layer. So now we swap the real data in for the save and back out again if the layer is muted. This fixes a few places that either prevented saving a muted layer or unmuted, saved, and re-muted. We no longer need to do any of that. Note that you still can't edit a muted layer. That would be bad given the current implementation. An alternative implementation would be to not compose muted layers. That feature already exists in Pcp but there's a significant semantic difference: it will not include muted layers in any layer stack, unlike the SdfLayer approach which leaves muted layers in the layer stack but makes it so they have no opinions. The Pcp approach drops any refPtr to the muted layers, likely causing them to be destroyed. Dropping muted layers from the layer stack and possibly destroying them violate our current expectations. (Internal change: 2354751)
- Loading branch information
Showing
1 changed file
with
75 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters