阶段四收尾:面板两行布局(row/expand/fill)+ 英文输出 + 混淆名对照表

- ViewInstaller:用 Table.row()/Cell.expand()+fill()/setFillParent 排出"
  按钮一行、可滚动文字区一行"的面板;修掉把 setDebug 当成 setFillParent 的误用
- Scene2dPanel:按钮 isChecked/setChecked 与 Label.setText 改用对照表定名,
  修掉"点一次反复触发"与"文字不刷新"两个 bug
- SceneReader:面板输出改英文(编辑器缺中文字形,中文会渲染成方块)
- 新增 tools/obfmap/MapMethods.java:载荷 vs 上游 libGDX 的字节码指纹比对工具
- 新增 混淆名对照表.md:类/方法/字段映射、推导办法、已踩的坑、验证状态
This commit is contained in:
tianmo committed 2026-10-16 14:06:42 +08:00
1 parent 2e7ab7c33c
commit 8f7b72271f
8 files changed
+677 -52

No files matched your search

+10 -8
View File
@@ -22,13 +22,15 @@ public final class SceneReader {
public static String read(ClassLoader editorLoader, Object stage) {
StringBuilder out = new StringBuilder();
out.append("=== 场景树里的对象 ===\n");
// 面板里的文字全部用英文:编辑器这套运行时只装了 NotoSans 拉丁字形,
// 中文会渲染成一排小方块(tofu)。
out.append("=== Scene actors ===\n");
try {
listActors(stage, out, 0, 0);
} catch (Throwable error) {
out.append("读取失败: ").append(error).append('\n');
out.append("read failed: ").append(error).append('\n');
}
out.append("=== 编辑器进程里的窗口 ===\n");
out.append("=== Editor windows ===\n");
for (Window window : Window.getWindows()) {
if (window.isVisible()) {
out.append(" ").append(window.getClass().getName()).append(" ")
@@ -38,16 +40,16 @@ public final class SceneReader {
}
}
}
out.append("\n=== 编辑器实例可达的自建对象 ===\n");
out.append("\n=== Objects reachable from Editor ===\n");
try {
Object editor = findEditor(editorLoader);
if (editor == null) {
out.append("(还没等到编辑器实例)\n");
out.append("(editor instance not ready yet)\n");
} else {
walk(editor, out);
}
} catch (Throwable error) {
out.append("读取失败: ").append(error).append('\n');
out.append("read failed: ").append(error).append('\n');
}
return out.toString();
}
@@ -90,7 +92,7 @@ public final class SceneReader {
for (java.awt.Component child : container.getComponents()) {
out.append(indent(depth)).append(child.getClass().getName());
if (child instanceof java.awt.Container) {
out.append(" 子组件=").append(((java.awt.Container) child).getComponentCount());
out.append(" children=").append(((java.awt.Container) child).getComponentCount());
}
out.append('\n');
if (child instanceof java.awt.Container) {
@@ -137,7 +139,7 @@ public final class SceneReader {
if (name.startsWith("java.") || name.startsWith("javax.") || name.startsWith("sun.")
|| name.startsWith("org.lwjgl") || name.startsWith("com.badlogic")) continue;
Field[] fields = current.getClass().getDeclaredFields();
out.append(indent(depth)).append(name).append(" 字段数=").append(fields.length)
out.append(indent(depth)).append(name).append(" fields=").append(fields.length)
.append('\n');
printed++;
if (depth >= 2) continue;