列表滚动(第二版):给列表单元格固定高度 360(Cell.height 载荷名 I,(F)LdR; 指纹确认)+ setForceScroll(false,true)(ScrollPane.I(ZZ)V 指纹确认);并把 setForceScroll/setOverscroll/Cell 尺寸方法写进 anchors.tsv+names.tsv

This commit is contained in:
tianmo committed 2026-10-16 16:15:35 +08:00
1 parent f558a4e4aa
commit d59287937d
3 files changed
+32

No files matched your search

+13
View File
@@ -74,3 +74,16 @@ com/badlogic/gdx/scenes/scene2d/ui/ScrollPane B (ZZ)V setScrollingDisabled
com/badlogic/gdx/scenes/scene2d/ui/ScrollPane L (FFFF)V scrollTo
com/badlogic/gdx/scenes/scene2d/ui/ScrollPane D (Ldl;)V addActor
com/badlogic/gdx/scenes/scene2d/ui/ScrollPane D (Ldl;Z)Z removeActor
# ---- ScrollPane / Cell 的滚动与尺寸方法(用于把面板列表改成可滚动;依据:MapMethods 指纹比对)----
# ScrollPane:B(ZZ)V=setScrollingDisabled、I(ZZ)V=setForceScroll、L(ZZ)V=setOverscroll
#(候选顺序 size/… 已核对;踩坑:把 B(ZZ) 当 setForceScroll 用,等于关掉纵向滚动)
com/badlogic/gdx/scenes/scene2d/ui/ScrollPane I (ZZ)V setForceScroll
com/badlogic/gdx/scenes/scene2d/ui/ScrollPane L (ZZ)V setOverscroll
# Cell 的 (F)LdR; 成组按声明顺序:B=size L=width I=height S=minWidth C=minHeight Z=prefWidth V=prefHeight
dR B (F)LdR; size
dR L (F)LdR; width
dR I (F)LdR; height
dR S (F)LdR; minWidth
dR C (F)LdR; minHeight
dR Z (F)LdR; prefWidth
dR V (F)LdR; prefHeight
Can't render this file because it contains an unexpected character in line 72 and column 99.
+9
View File
@@ -52,8 +52,10 @@ com/badlogic/gdx/scenes/scene2d/ui/ScrollPane D (ILdl;)V addActorAt
com/badlogic/gdx/scenes/scene2d/ui/ScrollPane D (Lcom/badlogic/gdx/scenes/scene2d/ui/ScrollPane$ScrollPaneStyle;)V setStyle
com/badlogic/gdx/scenes/scene2d/ui/ScrollPane D (Ldl;)V addActor
com/badlogic/gdx/scenes/scene2d/ui/ScrollPane D (Ldl;Z)Z removeActor
com/badlogic/gdx/scenes/scene2d/ui/ScrollPane I (ZZ)V setForceScroll
com/badlogic/gdx/scenes/scene2d/ui/ScrollPane L (FFFF)V scrollTo
com/badlogic/gdx/scenes/scene2d/ui/ScrollPane L (Ldl;)Z removeActor
com/badlogic/gdx/scenes/scene2d/ui/ScrollPane L (ZZ)V setOverscroll
com/badlogic/gdx/scenes/scene2d/ui/Slider D ()Lcom/badlogic/gdx/scenes/scene2d/ui/Slider$SliderStyle; getStyle
com/badlogic/gdx/scenes/scene2d/ui/Slider D ([FF)V setSnapToValues
com/badlogic/gdx/scenes/scene2d/ui/Slider init ()Z isDragging
@@ -78,10 +80,12 @@ com/badlogic/gdx/scenes/scene2d/ui/Window D (LJ;FFFFF)V drawStageBackground
com/badlogic/gdx/scenes/scene2d/ui/Window D (Lcom/badlogic/gdx/scenes/scene2d/ui/Window$WindowStyle;)V setStyle
com/badlogic/gdx/scenes/scene2d/ui/Window StackMapTable ()F getPrefWidth
dR B ()V row
dR B (F)LdR; size
dR B (LdR;)V merge
dR B (LeN;)LdR; height
dR B (Z)LdR; uniform
dR C ()LdR; left
dR C (F)LdR; minHeight
dR C (LeN;)LdR; prefWidth
dR Code (LeN;)LdR; spaceRight
dR D ()LdR; fill
@@ -94,14 +98,19 @@ dR D (Z)LdR; fill
dR D (ZZ)LdR; uniform
dR F ()LdR; grow
dR F (LeN;)LdR; spaceBottom
dR I (F)LdR; height
dR I (LeN;)LdR; minHeight
dR L ()V clear
dR L (F)LdR; width
dR L (LeN;)LdR; minWidth
dR S ()LdR; top
dR S (F)LdR; minWidth
dR SourceFile (LeN;)LdR; padRight
dR StackMapTable ()LdR; expand
dR String ()LdR; uniform
dR V (F)LdR; prefHeight
dR V (LeN;)LdR; space
dR Z (F)LdR; prefWidth
dR Z (LeN;)LdR; prefHeight
dR toString ()Ljava/lang/String; toString
dl B ()V clearListeners
1 # 合并后的名字映射表:MapMethods(gdx-1.11.0) 指纹自动 + 手动/实测锚点覆盖
52 com/badlogic/gdx/scenes/scene2d/ui/ScrollPane
53 com/badlogic/gdx/scenes/scene2d/ui/ScrollPane
54 com/badlogic/gdx/scenes/scene2d/ui/ScrollPane
55 com/badlogic/gdx/scenes/scene2d/ui/ScrollPane
56 com/badlogic/gdx/scenes/scene2d/ui/ScrollPane
57 com/badlogic/gdx/scenes/scene2d/ui/ScrollPane
58 com/badlogic/gdx/scenes/scene2d/ui/ScrollPane
59 com/badlogic/gdx/scenes/scene2d/ui/Slider
60 com/badlogic/gdx/scenes/scene2d/ui/Slider
61 com/badlogic/gdx/scenes/scene2d/ui/Slider
80 com/badlogic/gdx/scenes/scene2d/ui/Window
81 com/badlogic/gdx/scenes/scene2d/ui/Window
82 dR
83 dR
84 dR
85 dR
86 dR
87 dR
88 dR
89 dR
90 dR
91 dR
98 dR
99 dR
100 dR
101 dR
102 dR
103 dR
104 dR
105 dR
106 dR
107 dR
108 dR
109 dR
110 dR
111 dR
112 dR
113 dR
114 dR
115 dR
116 dl
@@ -126,6 +126,13 @@ public final class ObjectPanel {
cell = call(root, Obf.TABLE_ADD, new Class<?>[] {actorClass}, cellClass, scroll);
layoutCell(cell, Obf.CELL_TOP, Obf.CELL_EXPAND, Obf.CELL_FILL);
state.listCell = cell;
try {
// 给列表一个**固定高度**:这样 ScrollPane 必定比内容矮,可滚范围(maxY)一定 > 0。
// Cell.height(float) 的载荷名是 `I`(描述符 (F)LdR;,MapMethods 指纹确认)。
call(cell, "I", new Class<?>[] {float.class}, cellClass, Float.valueOf(360f));
} catch (Throwable error) {
System.err.println("[panel] 列表固定高度设置失败: " + error);
}
wire(loader, refresh, new Runnable() {
@Override
@@ -553,6 +560,9 @@ public final class ObjectPanel {
method.invoke(state.listScroll, Boolean.FALSE, Boolean.FALSE);
break;
}
// 再打开"强制纵向滚动":setForceScroll 在载荷里叫 `I`((ZZ)V,指纹确认 ~2/3)
call(state.listScroll, "I", new Class<?>[] {boolean.class, boolean.class}, void.class,
Boolean.FALSE, Boolean.TRUE);
} catch (Throwable error) {
System.err.println("[panel] 恢复滚动失败: " + error);
}