feat(v2): T-309 no startup foreground grab, auto-close popup, rename buttons

- Comment out Gio's startup SetForegroundWindow/SetFocus in the vendored
  os_windows.go (marked SILVER-POSE PATCH; reverts on re-vendor) so the
  window no longer steals foreground on launch. Gio has no option for this.
- The fall confirm popup auto-closes 5s after opening (op.InvalidateCmd
  schedules the redraw even with no live frames); '我已知晓' still closes early.
- Rename save buttons to 保存摄像头参数 / 保存常用检测参数. Cross-compiles for Windows.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
ila
2026-07-23 22:00:44 +08:00
co-authored by Claude Opus 4.8
parent d92b53d7a3
commit aced262f6b
3 changed files with 29 additions and 4 deletions
+4 -2
View File
@@ -112,8 +112,10 @@ func newWindow(win *callbacks, options []Option) {
defer winMap.Delete(w.hwnd)
w.Configure(options)
w.ProcessEvent(Win32ViewEvent{HWND: uintptr(w.hwnd)})
windows.SetForegroundWindow(w.hwnd)
windows.SetFocus(w.hwnd)
// SILVER-POSE PATCH (T-309): do not steal foreground/focus on startup.
// Re-applying `go mod vendor` reverts this; see progress.md.
// windows.SetForegroundWindow(w.hwnd)
// windows.SetFocus(w.hwnd)
// Since the window class for the cursor is null,
// set it here to show the cursor.
w.SetCursor(pointer.CursorDefault)