mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-07-04 20:24:47 +00:00
Issue #453 Update definetext only when the current font is used by that tag
This commit is contained in:
@@ -18,6 +18,7 @@ package com.jpexs.decompiler.flash.gui;
|
||||
|
||||
import com.jpexs.decompiler.flash.SWF;
|
||||
import com.jpexs.decompiler.flash.configuration.Configuration;
|
||||
import com.jpexs.decompiler.flash.tags.DefineTextTag;
|
||||
import com.jpexs.decompiler.flash.tags.Tag;
|
||||
import com.jpexs.decompiler.flash.tags.base.FontTag;
|
||||
import com.jpexs.decompiler.flash.tags.base.TextTag;
|
||||
@@ -259,12 +260,15 @@ public class FontPanel extends JPanel implements ActionListener {
|
||||
oldchars += c;
|
||||
}
|
||||
|
||||
int fontId = ft.getFontId();
|
||||
if (updateTextsCheckBox.isSelected()) {
|
||||
for (Tag tag : swf.tags) {
|
||||
if (tag instanceof TextTag) {
|
||||
TextTag textTag = (TextTag) tag;
|
||||
String text = textTag.getFormattedText(textTag.getSwf().tags);
|
||||
mainPanel.saveText(textTag, text);
|
||||
if (textTag.getFontIds(swf.tags).contains(fontId)) {
|
||||
String text = textTag.getFormattedText(textTag.getSwf().tags);
|
||||
mainPanel.saveText(textTag, text);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user