Skip to content

Commit 6295922

Browse files
midagedevclaude
andauthored
docs(desktop): the GTK4 launch-event hole now has an upstream address (GDK-295) (#43)
The cold-start argv workaround existed because wails' default Linux host never emits ApplicationLaunchedWithUrl. That hole is now filed and fixed upstream as wailsapp/wails#6000 — runtime-proven A/B in a headless container, GTK3 non-regression included. Point every comment that states the hole at that number, and say what becomes possible when a pin containing it lands: Linux moves to DeferToEvent like Windows. Co-authored-by: midagedev <midagedev@users.noreply.github.com> Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
1 parent 398a3d4 commit 6295922

2 files changed

Lines changed: 7 additions & 4 deletions

File tree

‎desktop/README.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ both so the rest of the tree can point here instead of restating either.
1414
| --- | --- | --- | --- |
1515
| darwin | `desktop/build-app.sh` → `Gadak-<ver>-arm64.dmg` (signed/notarized) | yes | yes (Apple Event; argv is not applied) |
1616
| windows | `desktop/build-windows.ps1` → `Gadak-<ver>-windows-<x64\|arm64>.zip` (unsigned; GDK-211) | yes (from 0.16) | yes when argv is exactly one `://` argument (wails `pkg/application/application_windows.go`); otherwise argv |
17-
| linux | `desktop/build-linux.sh` → AppDir / AppImage | no — from-source only | no (GTK4 never emits it; argv is applied) |
17+
| linux | `desktop/build-linux.sh` → AppDir / AppImage | no — from-source only | no (GTK4 never emits it — fix sent upstream, wailsapp/wails#6000; argv is applied) |
1818

1919
The in-app Jira/Confluence browse pane is still darwin-only (`embed_darwin.go`; other GOOS use the stub in `embed_other.go`).
2020

‎desktop/main.go‎

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,9 @@ type coldStartDecision struct {
8080
// pkg/application/application_windows.go:159-162). Every other argv
8181
// shape is ignored by wails, so argv is the fallback.
8282
// - linux (and anything else): argv. GTK4 run() in the same wails pin
83-
// (application_linux.go:89-99) does not emit the event.
83+
// (application_linux.go:89-99) does not emit the event. Fix sent
84+
// upstream as wailsapp/wails#6000 (GDK-295); when a pin containing it
85+
// lands, Linux can move to DeferToEvent like Windows.
8486
func coldStartDecisionFor(goos string, args []string) coldStartDecision {
8587
switch goos {
8688
case "darwin":
@@ -97,7 +99,7 @@ func coldStartDecisionFor(goos string, args []string) coldStartDecision {
9799

98100
// wailsEmitsLaunchURL is the argv shape wails v3.0.0-beta.9 special-cases
99101
// on Windows (application_windows.go:159-162). GTK3 has the same check;
100-
// GTK4, which this pin compiles, does not.
102+
// GTK4, which this pin compiles, does not (upstream fix: wailsapp/wails#6000).
101103
func wailsEmitsLaunchURL(args []string) bool {
102104
return len(args) == 2 && strings.Contains(args[1], "://")
103105
}
@@ -355,7 +357,8 @@ func run() error {
355357
window.OnWindowEvent(events.Common.WindowRuntimeReady, func(*application.WindowEvent) {
356358
log.Print("wails runtime ready — --wails-draggable listeners are attached")
357359
// Cold-start URL source is coldStartDecisionFor, not "!= darwin".
358-
// Linux always reads argv (GTK4 does not emit ApplicationLaunchedWithUrl).
360+
// Linux always reads argv (GTK4 does not emit ApplicationLaunchedWithUrl;
361+
// fix sent upstream as wailsapp/wails#6000).
359362
// Windows reads argv only when wails will not emit the event
360363
// (len(os.Args) != 2 or the single arg has no "://"). macOS never
361364
// reads argv. Nothing is handed to the webview until this event:

0 commit comments

Comments
 (0)