feat(run): keep service debugging in the Services tool window (#1844)

Closes #1684. Debug and rerun started from the Services tool window used startSession(), which opened the Debug tool window whenever run.showOnStart was on. Services-originated debug sessions and reruns now start with show: false and stay in the Services detail pane (in-place launches and reruns keep that origin; a breakpoint hit still shows the paused session). Debug from the toolbar, gutter, context menu and the Debug window keeps opening the Debug window. Also: palette themes inherit the macOS window button colours, and the title bar's fullscreen buttons skip Tauri calls outside Tauri (fixes the theme-token and title-bar test failures on main).

Co-authored-by: xtr-hub <242808782+xtr-hub@users.noreply.github.com>
This commit is contained in:
xtr-hub
2026-11-08 00:46:39 +08:00
committed by GitHub
co-authored by xtr-hub
parent f407880204
commit b790a9ddb6
16 changed files with 314 additions and 92 deletions
+3 -1
View File
@@ -73,7 +73,7 @@ export function jdwpLaunch(config: RunConfig): RunConfig | null {
}
/** Runs `config` with a JDWP agent and attaches the Java debugger to every JVM it starts. */
export async function debugWithAgent(config: RunConfig): Promise<boolean> {
export async function debugWithAgent(config: RunConfig, show?: boolean): Promise<boolean> {
const launch = jdwpLaunch(config);
if (!launch) return false;
let sessionId: string | null = null;
@@ -88,10 +88,12 @@ export async function debugWithAgent(config: RunConfig): Promise<boolean> {
port,
process: runId,
runConfig: config,
show,
});
};
const session = await startRun(config, undefined, undefined, {
launch,
show,
onLine: (line) => {
const port = jdwpListeningPort(line);
if (port === null) return;