feat: surface codex windows sandbox progress

This commit is contained in:
AI Bot
2026-06-01 19:16:23 +08:00
parent b0a778ee68
commit 94e0cc8bad
12 changed files with 141 additions and 10 deletions

View File

@@ -1525,8 +1525,9 @@ public final class BossUi {
JSONObject tokenUsage = progress == null ? null : progress.optJSONObject("tokenUsage");
JSONArray mcpServers = progress == null ? null : progress.optJSONArray("mcpServers");
JSONObject remoteControl = progress == null ? null : progress.optJSONObject("remoteControl");
JSONObject windowsSandbox = progress == null ? null : progress.optJSONObject("windowsSandbox");
boolean hasRuntimeStatus = modelRoute != null || tokenUsage != null ||
(mcpServers != null && mcpServers.length() > 0) || remoteControl != null;
(mcpServers != null && mcpServers.length() > 0) || remoteControl != null || windowsSandbox != null;
if (hasRuntimeStatus) {
card.addView(divider(context));
card.addView(sectionTitle(context, "运行状态"));
@@ -1596,6 +1597,27 @@ public final class BossUi {
));
}
}
if (windowsSandbox != null) {
String status = windowsSandbox.optString("status", "").trim();
String setupMode = windowsSandbox.optString("setupMode", "").trim();
String error = windowsSandbox.optString("error", "").trim();
if (!TextUtils.isEmpty(status) || !TextUtils.isEmpty(setupMode)) {
StringBuilder label = new StringBuilder("Windows 沙箱");
if (!TextUtils.isEmpty(status)) {
label.append(" ").append(status);
}
if (!TextUtils.isEmpty(setupMode)) {
label.append(" · ").append(setupMode);
}
card.addView(detailRow(
context,
"",
label.toString(),
error,
"failed".equals(status)
));
}
}
}
JSONArray toolActivities = progress == null ? null : progress.optJSONArray("toolActivities");