Files
silver_pose/v2/internal/ui/screen_windows.go
T
ilaandClaude Opus 4.8 550e6ad3ca feat(v2): T-308A window 80% of screen, 2x3 gallery, Esc close, button states
- Window opens at 80% of the primary display (Windows GetSystemMetrics).
- Gallery is now 2 columns x 3 rows and the right panel is narrower.
- Esc closes the full-image viewer (key focus + filter).
- Start/Stop grey out per running state (gtx.Disabled drops input); a hard
  ReportIssue resets running so Start re-enables. Cross-compiles for Windows.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 21:16:37 +08:00

19 lines
486 B
Go

//go:build windows
package ui
// SM_CXSCREEN / SM_CYSCREEN return the primary display size in pixels.
const (
smCXScreen = 0
smCYScreen = 1
)
var procGetSystemMetrics = user32.NewProc("GetSystemMetrics")
// screenSize returns the primary display size in pixels, or (0, 0) if unavailable.
func screenSize() (int, int) {
width, _, _ := procGetSystemMetrics.Call(uintptr(smCXScreen))
height, _, _ := procGetSystemMetrics.Call(uintptr(smCYScreen))
return int(width), int(height)
}