[v3/macOS] Restore title-bar controls across SetFrameless transitions
Summary
PR #5866 introduced native rounded-corner frameless behavior on macOS, but the runtime SetFrameless path does not synchronize the minimise, close, and maximise/fullscreen button states.
Evidence
- Merged implementation: https://github.com/wailsapp/wails/pull/5866
- Unresolved review finding: https://github.com/wailsapp/wails/pull/5866#discussion_r3694731705
- Current
masterstill configures the buttons only during window creation; the runtime transition path changes style/title state without updating the controls.
Observed code-path behavior:
- normal โ
SetFrameless(true): native-rounded frameless mode retains visible traffic-light controls; - native-rounded frameless โ
SetFrameless(false): controls remain hidden instead of restoring configured button states.
This is a macOS runtime API regression. It is user-visible but there is no crash, security, data-loss, or build-failure evidence.
Acceptance criteria
- Entering native-default frameless mode hides the title-bar controls.
- Leaving native-default frameless mode restores
MinimiseButtonState,CloseButtonState, and the effective maximise/fullscreen state. - Square/custom-radius borderless behavior remains unchanged.
- Focused tests cover both transition directions and configured button states where practical.
- Native macOS validation is recorded; any platform limitation is explicit.
IMPLEMENTATION.mdis updated only if the change touches tracked GTK4/GTK3 code (not expected).
Validation
Run focused application tests, a Darwin build/test path, git diff --check, and coderabbit --plain before commit.
Related: #5866
wailsapp/wails#4516 - fix(macOS): Use visibleFrame for window centering to exclude menu bar [merged]
wailsapp/wails#4962 - fix(v3/macos): guard InvisibleTitleBarHeight and fix top-corner resize shaking [merged]
wailsapp/wails#5307 - feat(v3): add mac.DisableEscapeExitsFullscreen opt-in for fullscreen Esc [merged]
wailsapp/wails#5319 - fix(v3/darwin): add FullscreenButtonState and resolve NSWindowZoomButton conflict [merged]
wailsapp/wails#5467 - fix(v3/darwin): runtime effectiveZoomButtonState reconciliation + changelog for ๐ Related PRs
#5319 [merged]
wailsapp/wails#5582 - fix(v3/windows): keep DWM animations when SetFrameless(true) is called [merged]
wailsapp/wails#5800 - fix: hide GTK corners in frameless mode [merged]
wailsapp/wails#5866 - fix(v3): preserve native macOS frameless corners [merged]
๐ Issue Planner
Check the box below or use the @coderabbitai plan command to generate an implementation plan and prompts that you can use with your favorite coding assistant.
- [ ] Create Plan
๐งช Issue enrichment is currently in open beta.
You can configure auto-planning by selecting labels in the issue_enrichment configuration.
To disable automatic issue enrichment, add the following to your .coderabbit.yaml:
issue_enrichment:
auto_enrich:
enabled: false
๐ฌ Have feedback or questions? Drop into our discord!
Implemented and pushed the focused fix in PR #5870 (commit a3982c1d3). Runtime transitions now hide native-default frameless traffic-light controls and restore configured minimise/close plus effective maximise/fullscreen state when leaving; square and custom-radius paths remain unchanged.
Validation evidence:
- focused transition/state tests pass
- full
webview_window_options_test.gosuite passes via file-list testing with temporary declarations for unrelated native package types git diff --checkpasses- equivalent plain CodeRabbit local review completed with no findings (
coderabbit --plainis unsupported by the installed CLI version)
Native AppKit validation is explicitly pending macOS CI/manual testing: this Linux host lacks Apple frameworks/cross-compiler, and the full package also cannot build locally without GTK4/WebKitGTK development packages.
Morning release review against current origin/master d40990bc0: PR #5870 merges cleanly in a no-commit integration check, and no code change was needed. Focused TestEffectiveMacWindowButtonStates/TestEffectiveZoomButtonState and the full webview_window_options_test.go file-list suite passed on the tentative merge. A Darwin/amd64 server-mode application test binary also cross-compiled successfully, git diff --check passed, and the local CodeRabbit committed review against origin/master completed with no findings. GitHub reports all PR checks green, including Run Go Tests v3 on macos-latest; there are no reviews or unresolved review threads. Native AppKit UI transition validation remains the only limitation because this worker is Linux and lacks Apple frameworks; keep the issue/PR In Progress pending maintainer review or native manual confirmation.