Taglist edit fix 2

This commit is contained in:
Jindra Petřík
2022-11-01 21:51:18 +01:00
parent 9cb0510d6e
commit 0896f45615
3 changed files with 17 additions and 15 deletions
@@ -50,6 +50,7 @@ import com.jpexs.decompiler.flash.gui.controls.JPersistentSplitPane;
import com.jpexs.decompiler.flash.gui.controls.NoneSelectedButtonGroup;
import com.jpexs.decompiler.flash.gui.editor.DebuggableEditorPane;
import com.jpexs.decompiler.flash.gui.editor.LinkHandler;
import com.jpexs.decompiler.flash.gui.tagtree.AbstractTagTreeModel;
import com.jpexs.decompiler.flash.gui.tagtree.TagTreeModel;
import com.jpexs.decompiler.flash.helpers.HighlightedText;
import com.jpexs.decompiler.flash.helpers.HighlightedTextWriter;
@@ -1136,10 +1137,10 @@ public class ActionPanel extends JPanel implements SearchListener<ScriptSearchRe
addScriptListener(onScriptComplete);
TagTreeModel ttm = (TagTreeModel) mainPanel.tagTree.getModel();
AbstractTagTreeModel ttm = mainPanel.getCurrentTree().getModel();
TreePath tp = ttm.getTreePath(result.getSrc());
mainPanel.tagTree.setSelectionPath(tp);
mainPanel.tagTree.scrollPathToVisible(tp);
mainPanel.getCurrentTree().setSelectionPath(tp);
mainPanel.getCurrentTree().scrollPathToVisible(tp);
}