Fix usage panel sizing and localization - #95
Conversation
Automated review (Codex)The patch introduces localization and installer regressions, and the new "yesterday" view can become stale across midnight. The single-instance activation protocol also has a silent-failure race. [P2] Preserve [P2] Quote the Run-key command — [P2] Invalidate "yesterday" rows at the date boundary — [P3] Handle a missing activation event — Generated with Codex CLI, dispatched via Claude Code. |
Heads-up: a large Windows change is landing in
|
Update: #96 has now mergedQuick status update, and an amendment to what I said last time. #96 landed in One correction to my earlier commentI said the dynamic panel height work was superseded. That was only half right:
Where things stand, per file
I don't want this to sit indefinitely. If I don't hear from you within a week, I'll land the pieces above myself with attribution to you and close this PR — no hard feelings either way, and the installer is still yours to open whenever you like. |
Git Bash / MSYS 會塞一個 LANG 進環境變數(通常是 en_US.UTF-8), 不代表使用者的系統語言,卻蓋掉了 GetUserDefaultUILanguage 的結果。 Windows 上只保留 USAGE_LANG 與 TT_LANG 這兩個顯式覆寫,其他平台不變。 問題由 PR #95 (zenghuizhu69-hub) 指出;該 PR 的修法以 env is None 為 條件,會連帶讓 Linux/macOS 也不再尊重 LANG,故改以平台判斷實作。 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
What changed
LANGvalues and follow the Windows UI languageWhy
The panel could open at a stale height because it measured before WebView2 layout stabilized, and project-range updates bypassed the measurement path. The Codex heading was the only flexible item in an overcrowded header, so it collapsed to a single character. Windows language selection was startup-only and could be incorrectly forced to English by
LANG=C.UTF-8. Codex weekly usage could also select a model-specific reset window instead of the general account limit.User impact
The tray panel now fits its visible content without repeated button clicks, keeps the Codex name readable, exposes a persistent language selector, displays yesterday's totals, and reports the intended Codex weekly allowance.
Validation
178 passed, 1 skippedacross Windows-safe dynamic-height, language, tray, i18n, menubar-state, and Codex-loader testsgit diff --checkobjcdependency and is not runnable on Windows