mirror of
https://github.com/scratchfoundation/scratch-vm.git
synced 2024-12-23 14:32:59 -05:00
Sounds get updated in storage and vm runtime when they are updated in the sound editor. The updateSvg function ensures that the costume that was edited has an updated dataFormat property in the vm runtime. This is specifically for when pngs get edited in the vector editor. Their file format should then get updated to svg.
This commit is contained in:
parent
52c77d9fb0
commit
089df0a50f
1 changed files with 3 additions and 0 deletions
|
@ -513,6 +513,9 @@ class VirtualMachine extends EventEmitter {
|
|||
storage.DataFormat.SVG,
|
||||
(new TextEncoder()).encode(svg)
|
||||
);
|
||||
// If we're in here, we've edited an svg in the vector editor,
|
||||
// so the dataFormat should be 'svg'
|
||||
costume.dataFormat = storage.DataFormat.SVG;
|
||||
this.emitTargetsUpdate();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue