fix: 按钮管理/按钮编辑等所有设置页 UI 元素跟随 SETTINGS_THEME

之前只覆盖了设置首页和分组页的配色切换,但按钮管理页内的
统计卡片、操作 chip、分区卡片、折叠分组、编辑面板等 UI
组件仍然直接硬编码 getAnimalIslandTheme()。

补全遗漏的 6 个函数:
- createButtonManagerSummaryCard
- createButtonManagerActionChip
- createButtonManagerPolishedCard
- createButtonEditorSectionCard
- createButtonEditorCollapsibleSection
- buildButtonEditorPanelView
This commit is contained in:
7015725
2026-05-15 02:31:39 +08:00
parent efdcd3f187
commit 61a6bf1e72
3 changed files with 10 additions and 4 deletions

View File

@@ -609,6 +609,7 @@ FloatBallAppWM.prototype.createButtonManagerSummaryCard = function(parent, total
var isDark = this.isDarkTheme(); var isDark = this.isDarkTheme();
var C = this.ui.colors; var C = this.ui.colors;
var T = this.getAnimalIslandTheme(); var T = this.getAnimalIslandTheme();
this.applySettingsTheme(T, isDark, C, this.state.pendingUserCfg || this.config);
var card = new android.widget.LinearLayout(context); var card = new android.widget.LinearLayout(context);
card.setOrientation(android.widget.LinearLayout.VERTICAL); card.setOrientation(android.widget.LinearLayout.VERTICAL);
card.setPadding(this.dp(14), this.dp(10), this.dp(14), this.dp(10)); card.setPadding(this.dp(14), this.dp(10), this.dp(14), this.dp(10));
@@ -636,6 +637,7 @@ FloatBallAppWM.prototype.createButtonManagerSummaryCard = function(parent, total
FloatBallAppWM.prototype.createButtonManagerActionChip = function(text, textColor, strokeColor, onClickFn) { FloatBallAppWM.prototype.createButtonManagerActionChip = function(text, textColor, strokeColor, onClickFn) {
var T = this.getAnimalIslandTheme(); var T = this.getAnimalIslandTheme();
this.applySettingsTheme(T, this.isDarkTheme(), this.ui.colors, this.state.pendingUserCfg || this.config);
var tv = new android.widget.TextView(context); var tv = new android.widget.TextView(context);
tv.setText(String(text || "")); tv.setText(String(text || ""));
tv.setGravity(android.view.Gravity.CENTER); tv.setGravity(android.view.Gravity.CENTER);
@@ -681,6 +683,7 @@ FloatBallAppWM.prototype.createButtonManagerPolishedCard = function(parent, titl
var isDark = this.isDarkTheme(); var isDark = this.isDarkTheme();
var C = this.ui.colors; var C = this.ui.colors;
var T = this.getAnimalIslandTheme(); var T = this.getAnimalIslandTheme();
this.applySettingsTheme(T, isDark, C, this.state.pendingUserCfg || this.config);
var card = new android.widget.LinearLayout(context); var card = new android.widget.LinearLayout(context);
card.setOrientation(android.widget.LinearLayout.VERTICAL); card.setOrientation(android.widget.LinearLayout.VERTICAL);
card.setPadding(this.dp(14), this.dp(12), this.dp(14), this.dp(12)); card.setPadding(this.dp(14), this.dp(12), this.dp(14), this.dp(12));
@@ -724,6 +727,7 @@ FloatBallAppWM.prototype.createButtonEditorSectionCard = function(parent, title,
var isDark = this.isDarkTheme(); var isDark = this.isDarkTheme();
var C = this.ui.colors; var C = this.ui.colors;
var T = this.getAnimalIslandTheme(); var T = this.getAnimalIslandTheme();
this.applySettingsTheme(T, isDark, C, this.state.pendingUserCfg || this.config);
var box = new android.widget.LinearLayout(context); var box = new android.widget.LinearLayout(context);
box.setOrientation(android.widget.LinearLayout.VERTICAL); box.setOrientation(android.widget.LinearLayout.VERTICAL);
box.setPadding(this.dp(12), this.dp(10), this.dp(12), this.dp(10)); box.setPadding(this.dp(12), this.dp(10), this.dp(12), this.dp(10));
@@ -754,6 +758,7 @@ FloatBallAppWM.prototype.createButtonEditorCollapsibleSection = function(parent,
var isDark = this.isDarkTheme(); var isDark = this.isDarkTheme();
var C = this.ui.colors; var C = this.ui.colors;
var T = this.getAnimalIslandTheme(); var T = this.getAnimalIslandTheme();
this.applySettingsTheme(T, isDark, C, this.state.pendingUserCfg || this.config);
var expanded = defaultExpanded !== false; var expanded = defaultExpanded !== false;
var card = new android.widget.LinearLayout(context); var card = new android.widget.LinearLayout(context);
card.setOrientation(android.widget.LinearLayout.VERTICAL); card.setOrientation(android.widget.LinearLayout.VERTICAL);
@@ -832,6 +837,7 @@ FloatBallAppWM.prototype.buildButtonEditorPanelView = function() {
var isDark = this.isDarkTheme(); var isDark = this.isDarkTheme();
var C = this.ui.colors; var C = this.ui.colors;
var T = this.getAnimalIslandTheme(); var T = this.getAnimalIslandTheme();
this.applySettingsTheme(T, isDark, C, this.state.pendingUserCfg || this.config);
// 颜色配置 // 颜色配置
var bgColor = T.bg; var bgColor = T.bg;

View File

@@ -54,8 +54,8 @@
"size": 20392 "size": 20392
}, },
"th_14_panels.js": { "th_14_panels.js": {
"sha256": "a998d4d73051d2c9b5be57e570a51fa9cb4ffff1a9c8d5cff6f15a5c717311bb", "sha256": "6de693ddaaef58479aabfdfaab6d25eedfd95ce58e446064168f4591919a85f2",
"size": 245438 "size": 245961
}, },
"th_15_extra.js": { "th_15_extra.js": {
"sha256": "b607620f1900c1bd93ccbec8d901d4de53b3d36e9373877f4264442f79b9b956", "sha256": "b607620f1900c1bd93ccbec8d901d4de53b3d36e9373877f4264442f79b9b956",
@@ -68,5 +68,5 @@
}, },
"keyId": "toolhub-targets-2026-rsa3072", "keyId": "toolhub-targets-2026-rsa3072",
"schema": 2, "schema": 2,
"version": 20260514182858 "version": 20260514183135
} }

View File

@@ -1 +1 @@
dnlTNj0xaNuD3ovfDT5K25pIf3pe9cFqkgSVAUPO9NVReyXhJt2GU5S4H1OeayT2QF4GEB2SjsvDCLfmN4RFYrP99yhOdJ66zz1mgI8BNNorjRmR9kqs3REdDrZqUuMD50Nqebr01RrHUnksDIESf7Li9fnsFCpPSco+HEzU8tqkJiBv9en7R5rh7dYuMa1Hz7WVc7jRQsqWgnaPSH7czL5Ffv0R889Sa/PRwUJvWb462rDM0YMrjXJPcTCueX10ycgvvzPKfIBCAkG2MeWSfuL9TbDn+Dbe9am8og7bH3kMCduU7SyV7avVAo8M+x2NP4osVgageMAe8O4HLUXxUeDfAreoPSSHtSCYwd7bP7sjr1RS8s8WxubKUAc1Koqwf82kLar4ODPmLVgCW3U9O7pBNIdsZ3hpj4K+o35+Nn7X0vmeUfwVtNG8nOSQFGMshT60dasmOdefkU8OxdAc9rlS44QK8H/GS+6E7WAONUFYZxncgDh8ibHa7SFz8BKm cDTR/zljOOq1QJih3E682NuyYsbqs1tLLHp2zMJzWIxBcjeSkuI5DT4jgPQcpaqakWt0pu7zlIcI1iB1qT/51323zYhpeHOkMCisA9BnD38NetdOHtr13C/SGCJcGeMzhceQC/4XFuvCtnOfo5EL6BVuZpASrx0l89Axg24yp+lYNfOrr+ytzWhABcTWlY7nEVR8es3Gh8HKDC19mAGU61t3S6G0gPzw5o3WjqCET0yrVsOZmkfmMjCHhHsIWY5KYZet33oQ3fIrKSRFBofMD4fsDx4+ypyNgvAqdHqDQY79iZQJJ0aoaqBNFdL2+0kw1nq2L+RtCm7ccVzG9aDCGrmOSvjUt/saFr4lb19umtFFUUUL6Cw7aJF6yI0nn1c5QwEhlBLMcs1DeusC/4M9nQhfEkwTkOb8Jj7Dd1k4gZMB7nGz5TkbnHieY9ZWAAdSVKqtpzixLCBfi526/RBKKBGGprm9xOmhZEWYOXwAsFa9z67yRMVJPZYGCUvIn2+9