fix: refine island settings bottom layout

This commit is contained in:
7015725
2026-05-18 21:38:21 +08:00
parent df6f548c76
commit ae8abc2908
4 changed files with 29 additions and 19 deletions

View File

@@ -294,7 +294,7 @@ FloatBallAppWM.prototype.buildSettingsHomePanelView = function() {
this.applySettingsTheme(T, isDark, C, cfgTpl);
var useMonetHome = this.isSettingsMonetTheme ? this.isSettingsMonetTheme(cfgTpl) : false;
var panel = this.ui.createStyledPanel(this, 16);
try { panel.setBackground(this.ui.createRoundDrawable(T.bg, this.dp(18))); } catch(ePanelBg) {}
try { panel.setBackground(this.ui.createRoundDrawable(T.bg, this.dp(24))); } catch(ePanelBg) {}
var statusLabel = "已保存";
var statusValue = "当前生效";
var statusBg = T.card;
@@ -326,7 +326,7 @@ FloatBallAppWM.prototype.buildSettingsHomePanelView = function() {
try { scroll.setVerticalScrollBarEnabled(false); } catch(eSB) { safeLog(null, 'e', "catch " + String(eSB)); }
var box = new android.widget.LinearLayout(context);
box.setOrientation(android.widget.LinearLayout.VERTICAL);
box.setPadding(0, 0, 0, this.dp(4));
box.setPadding(0, 0, 0, this.dp(8));
scroll.addView(box);
scroll.setOnTouchListener(new JavaAdapter(android.view.View.OnTouchListener, { onTouch: function(v, e) { self.touchActivity(); return false; }}));
if (useMonetHome) {
@@ -376,13 +376,14 @@ FloatBallAppWM.prototype.buildSettingsHomePanelView = function() {
var bottom = new android.widget.LinearLayout(context);
bottom.setOrientation(android.widget.LinearLayout.VERTICAL);
bottom.setGravity(android.view.Gravity.CENTER);
bottom.setPadding(this.dp(8), this.dp(8), this.dp(8), this.dp(4));
bottom.setPadding(this.dp(14), this.dp(8), this.dp(14), this.dp(14));
bottom.setBackground(this.ui.createRoundDrawable(this.withAlpha(T.bg, isDark ? 0.88 : 0.96), this.dp(22)));
var deco = new android.widget.TextView(context);
deco.setText("🌿 ✿ ✿ 🌿");
deco.setText("🌿 ✿ ✿ 🌿");
deco.setGravity(android.view.Gravity.CENTER);
deco.setTextColor(this.withAlpha(T.primaryDeep, isDark ? 0.44 : 0.36));
deco.setTextSize(android.util.TypedValue.COMPLEX_UNIT_SP, 11);
bottom.addView(deco, new android.widget.LinearLayout.LayoutParams(-1, this.dp(18)));
deco.setTextColor(this.withAlpha(T.primaryDeep, isDark ? 0.36 : 0.30));
deco.setTextSize(android.util.TypedValue.COMPLEX_UNIT_SP, 10);
bottom.addView(deco, new android.widget.LinearLayout.LayoutParams(-1, this.dp(14)));
var btnSave = this.ui.createSolidButton(this, useMonetHome ? "保存" : "保存布置", T.primary, T.onPrimary, function() {
try {
self.touchActivity();
@@ -397,8 +398,14 @@ FloatBallAppWM.prototype.buildSettingsHomePanelView = function() {
});
btnSave.setText(useMonetHome ? "保存" : "💾 保存布置");
btnSave.setPadding(this.dp(18), 0, this.dp(18), 0);
bottom.addView(btnSave, new android.widget.LinearLayout.LayoutParams(-1, this.dp(46)));
panel.addView(bottom, new android.widget.LinearLayout.LayoutParams(-1, -2));
try { btnSave.setBackground(this.ui.createStrokeDrawable(T.primary, this.withAlpha(T.primaryDeep, isDark ? 0.26 : 0.18), this.dp(1), this.dp(23))); } catch(eSaveBg) {}
try { btnSave.setElevation(this.dp(2)); } catch(eSaveElev) {}
var saveLp = new android.widget.LinearLayout.LayoutParams(-1, this.dp(44));
saveLp.setMargins(this.dp(34), this.dp(4), this.dp(34), 0);
bottom.addView(btnSave, saveLp);
var bottomLp = new android.widget.LinearLayout.LayoutParams(-1, -2);
bottomLp.setMargins(this.dp(2), this.dp(4), this.dp(2), 0);
panel.addView(bottom, bottomLp);
return panel;
};

View File

@@ -843,10 +843,11 @@ FloatBallAppWM.prototype.buildToolAppShell = function(contentView, title, canBac
var root = new android.widget.FrameLayout(context);
var body = new android.widget.LinearLayout(context);
body.setOrientation(android.widget.LinearLayout.VERTICAL);
body.setPadding(this.dp(2), this.dp(2), this.dp(2), this.dp(2));
body.setBackground(this.ui.createStrokeDrawable(T.bg, this.withAlpha(T.stroke, isDark ? 0.42 : 0.70), this.dp(1), this.dp(24)));
// 外层薄荷容器本身就是整张“岛屿设置”卡片:四角统一圆角,并给底部留出完整收口。
body.setPadding(this.dp(6), this.dp(6), this.dp(6), this.dp(8));
body.setBackground(this.ui.createStrokeDrawable(T.bg, this.withAlpha(T.stroke, isDark ? 0.42 : 0.70), this.dp(1), this.dp(26)));
try { body.setClipToOutline(true); } catch(eClip) {}
try { body.setElevation(this.dp(16)); } catch(eElev) { safeLog(null, 'e', "catch " + String(eElev)); }
try { body.setElevation(this.dp(12)); } catch(eElev) { safeLog(null, 'e', "catch " + String(eElev)); }
root.addView(body, new android.widget.FrameLayout.LayoutParams(-1, -1));
var bar = new android.widget.LinearLayout(context);
@@ -901,7 +902,9 @@ FloatBallAppWM.prototype.buildToolAppShell = function(contentView, title, canBac
try { contentView.setElevation(0); } catch(eEl) { safeLog(null, 'e', "catch " + String(eEl)); }
host.addView(contentView, new android.widget.FrameLayout.LayoutParams(-1, -1));
}
body.addView(host, new android.widget.LinearLayout.LayoutParams(-1, 0, 1));
var hostLp = new android.widget.LinearLayout.LayoutParams(-1, 0, 1);
hostLp.setMargins(this.dp(6), 0, this.dp(6), this.dp(6));
body.addView(host, hostLp);
try {
var stripW = this.dp(24);

View File

@@ -54,12 +54,12 @@
"size": 21198
},
"th_14_panels.js": {
"sha256": "346aa3fdfa27022bb2d61d3302533be2e38461c9140e9f09d05822d39cbb4237",
"size": 261345
"sha256": "d14a0e9093918911406c314a5a27a75e50d2d52ed3771997729d193ff6514150",
"size": 261858
},
"th_15_extra.js": {
"sha256": "7db6431ad246c63e99c4c96dcf5903d38036efd6eed5c0da88bcfa0a0cd62ee0",
"size": 92377
"sha256": "e5a98a6f57d36f8f20f6b7d7f78069d87537c6f60cca4da73c5e2d780e77e908",
"size": 92583
},
"th_16_entry.js": {
"sha256": "e7c99c3dfbd6aedab05551426955081ae6cae034754f2f557cefa01dc75dc001",
@@ -68,5 +68,5 @@
},
"keyId": "toolhub-targets-2026-rsa3072",
"schema": 2,
"version": 20260518065021
"version": 20260518133544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