Skip to content

fix(app): prevent resize crash after Close File - #2603

Merged
wkentaro merged 2 commits into
mainfrom
fix/resize-after-close
Sep 3, 2026
Merged

wkentaro merged 2 commits into
mainfrom
fix/resize-after-close

Conversation

@wkentaro

@wkentaro wkentaro commented Sep 3, 2026

Copy link
Copy Markdown
Owner

Closes #2598.

Close File cleared the canvas pixmap but left the main window's Image live, so a fit-mode resize treated an empty canvas as loaded and divided by zero. The shared reset now restores that invariant.

Verified in both Fit Window and Fit Width with 29 focused E2E tests, Ruff, Ty, and a real GUI close-and-resize flow.

@wkentaro wkentaro self-assigned this Sep 3, 2026
@wkentaro wkentaro added the maintainer-approved pr: Maintainer reviewed this head and approves merging after required checks pass label Sep 3, 2026
@wkentaro
wkentaro merged commit 1f05a86 into main Sep 3, 2026
21 checks passed
@wkentaro
wkentaro deleted the fix/resize-after-close branch September 3, 2026 02:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintainer-approved pr: Maintainer reviewed this head and approves merging after required checks pass

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ZeroDivisionError on window resize after Close File in fit-window or fit-width mode

1 participant