mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-05-31 10:25:49 +00:00
Added Folder preview for sounds
This commit is contained in:
@@ -4,6 +4,7 @@ All notable changes to this project will be documented in this file.
|
||||
## [Unreleased]
|
||||
### Added
|
||||
- StartSound and StartSound2 show characterId/class in the tag tree
|
||||
- Folder preview for sounds
|
||||
|
||||
### Fixed
|
||||
- Debugger - getting children of top level variables
|
||||
|
||||
@@ -262,6 +262,11 @@ public class SoundStreamHead2Tag extends SoundStreamHeadTypeTag {
|
||||
public String toString() {
|
||||
return getName() + " (" + virtualCharacterId + ")";
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getUniqueId() {
|
||||
return "" + virtualCharacterId;
|
||||
}
|
||||
|
||||
//getNeededCharacters intentionally not defined
|
||||
@Override
|
||||
|
||||
@@ -272,6 +272,11 @@ public class SoundStreamHeadTag extends SoundStreamHeadTypeTag {
|
||||
return getName() + " (" + virtualCharacterId + ")";
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getUniqueId() {
|
||||
return "" + virtualCharacterId;
|
||||
}
|
||||
|
||||
//getNeededCharacters intentionally not defined
|
||||
@Override
|
||||
public void setSoundSize(boolean soundSize) {
|
||||
|
||||
@@ -243,6 +243,11 @@ public class DefineExternalStreamSound extends Tag implements CharacterIdTag, So
|
||||
public String toString() {
|
||||
return getName() + " (" + virtualCharacterId + ")";
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getUniqueId() {
|
||||
return "" + virtualCharacterId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void getTagInfo(TagInfo tagInfo) {
|
||||
|
||||
@@ -242,10 +242,12 @@ public class FolderListPanel extends JPanel {
|
||||
icon.paintIcon(l, g, x * CELL_WIDTH + BORDER_SIZE + PREVIEW_SIZE / 2 - icon.getIconWidth() / 2, y * CELL_HEIGHT + BORDER_SIZE + PREVIEW_SIZE / 2 - icon.getIconHeight() / 2);
|
||||
String s;
|
||||
if (treeItem instanceof Tag) {
|
||||
Tag t = (Tag) treeItem;
|
||||
String uniqueId = t.getUniqueId();
|
||||
s = ((Tag) treeItem).getTagName();
|
||||
if (treeItem instanceof CharacterTag) {
|
||||
s = s + " (" + ((CharacterTag) treeItem).getCharacterId() + ")";
|
||||
}
|
||||
if (uniqueId != null) {
|
||||
s = s + " (" + uniqueId + ")";
|
||||
}
|
||||
} else {
|
||||
s = treeItem.toString();
|
||||
}
|
||||
|
||||
@@ -6049,7 +6049,10 @@ public final class MainPanel extends JPanel implements TreeSelectionListener, Se
|
||||
|
||||
private void showFolderPreview(FolderItem item) {
|
||||
String folderName = item.getName();
|
||||
if (TagTreeModel.FOLDER_OTHERS.equals(folderName) || TagTreeModel.FOLDER_SCRIPTS.equals(folderName)) {
|
||||
if (TagTreeModel.FOLDER_OTHERS.equals(folderName)
|
||||
|| TagTreeModel.FOLDER_SCRIPTS.equals(folderName)
|
||||
|| TagTreeModel.FOLDER_SOUNDS.equals(folderName)
|
||||
) {
|
||||
showFolderList(tagTree.getFullModel().getTreePath(item));
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user