Skip to content

fix(layout): respect native maximum window heights - #114

Merged
qeude merged 3 commits into
mainfrom
t3code/fix/device-hub-window-height
Sep 30, 2026
Merged

qeude merged 3 commits into
mainfrom
t3code/fix/device-hub-window-height

Conversation

@qeude

@qeude qeude commented Sep 30, 2026 •

Copy link
Copy Markdown
Owner

Summary

Dia could retain a temporarily short native frame instead of filling its tile. Only windows with a current native maximum height may retain accepted compact sizes, preserving Device Hub previews.

fresh native maximum height absent -> discard acceptance; fill tile height
fresh native maximum height present -> accepted native size may shape the tile

Height constraints are not carried over from an old snapshot or window ID. Existing learned width constraints remain unchanged.

Evidence

  • Before: lifecycle regressions fail when all native constraints disappear or an unbounded replacement inherits a stale maximum height.
    After: both cases clear the height capability; the all-nil transition clears accepted sizing and restores full tile height.
  • Height-only snapshots preserve learned minimum and maximum width bounds; the regression failed before the fix and passes afterward.
  • python3 script/verify.py local --stage: build, all non-desktop Swift tests, workflow tests, and staging passed.
  • Focused native test DesktopE2ETests/testAppliedTargetConvergesWithRealWindowFrame: passed with Accessibility available; desktop session restored.
  • Desktop validation of the original fix: Dia fills 1,363 points; Device Hub preview remains 338 × 748.

Merge Danger

Door: two-way

Blast Radius: tiling

If optional native constraints are unavailable, compact acceptance is discarded and full tile height is requested.

Review in cubic

Note

Respect native maximum window heights in tiled layout

  • Windows without a native maximum tiled height no longer learn or use tiled-size acceptance, so unbounded windows keep their full requested height instead of shrinking to a stale compact frame.
  • The window-server constraint lookup now returns width and height limits as one WindowSizeConstraints value, and the Window model gains an optional maximumTiledHeight carried through discovery in SnapshotEngine.makeWindow (WindowBorderPrivateProviders.swift, Window.swift).
  • Reconciliation clears stored acceptance when the height capability disappears or the window goes fullscreen, and preserves learned width bounds when a new snapshot supplies only a height limit (WindowReconciliation.swift).
  • Behavioral Change: acceptedTiledSizes and acceptTiledWindowFrame now require a maximum tiled height; stale accepted sizes from unbounded windows are ignored (Layout.swift, RuntimeState.swift).

Macroscope summarized 4b7df31.

Comment thread Sources/DefiRuntime/WindowReconciliation.swift

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All reported issues were addressed across 9 files

Reply with feedback, questions, or to request a fix.

Re-trigger cubic

Comment thread Sources/DefiRuntime/RuntimeState.swift Outdated
@macroscopeapp

macroscopeapp Bot commented Sep 30, 2026 •

Copy link
Copy Markdown

Approvability

Verdict: Approved at 4b7df31

Macroscope's review found this PR approvable — This is a focused, well-scoped fix to native window-size handling, with additive state propagation and targeted lifecycle/layout regression coverage. Its runtime effect is limited to discarding stale compact sizing for windows without a current native height bound while preserving existing width behavior.

You can add or adjust custom eligibility rules. Learn more.

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All reported issues were addressed across 3 files (changes from recent commits).

Reply with feedback, questions, or to request a fix.

Re-trigger cubic

Comment thread Sources/DefiRuntime/WindowReconciliation.swift
@qeude
qeude merged commit b849b8a into main Sep 30, 2026
4 checks passed
@qeude
qeude deleted the t3code/fix/device-hub-window-height branch September 30, 2026 19:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant