Fix #1256 Cant paste all faces at once

Fix multiple GIF HUDs when pressing button multiple times
This commit is contained in:
JannisX11 2022-01-21 23:28:38 +01:00
parent c61a20b12a
commit 36a59630ec
2 changed files with 4 additions and 1 deletions

View File

@ -22,6 +22,9 @@ const Screencam = {
onConfirm: function(formData) {
let background = formData.color.toHex8String() != '#00000000' ? formData.color.toHexString() : undefined;
this.hide();
if (document.getElementById('gif_recording_frame')) {
document.getElementById('gif_recording_frame').remove();
}
Screencam.createGif({
length_mode: formData.length_mode,
length: limitNumber(formData.length, 0.1, 24000),

View File

@ -1153,7 +1153,7 @@ const UVEditor = {
} else {
UVEditor.clipboard.forEach(tag => {
elements.forEach(el => {
if (Project.box_uv && el instanceof Cube)
if (Project.box_uv && el instanceof Cube) return;
if ((el instanceof Cube && tag instanceof CubeFace) || (el instanceof Mesh && tag instanceof MeshFace)) {
let key = tag.direction;
if (el.faces[key]) {