mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-09-24 23:10:46 +00:00
Fixed Move tag to action did not remove original tag
Properly handle pins on moveto action
This commit is contained in:
@@ -371,4 +371,24 @@ public class PinsPanel extends JPanel {
|
||||
}
|
||||
save();
|
||||
}
|
||||
|
||||
public void replaceItem(TreeItem oldItem, TreeItem newItem) {
|
||||
for (int i = 0; i < items.size(); i++) {
|
||||
if (items.get(i) == oldItem) {
|
||||
items.set(i, newItem);
|
||||
rebuild();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void removeItem(TreeItem item) {
|
||||
for (int i = 0; i < items.size(); i++) {
|
||||
if (items.get(i) == item) {
|
||||
items.remove(i);
|
||||
rebuild();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user