Skip to content

fix: restore saved export destination mode on image open#603

Merged
marcinz606 merged 1 commit into
marcinz606:mainfrom
paulglover:fix/export-destination-mode-restore
Jul 22, 2026
Merged

fix: restore saved export destination mode on image open#603
marcinz606 merged 1 commit into
marcinz606:mainfrom
paulglover:fix/export-destination-mode-restore

Conversation

@paulglover

Copy link
Copy Markdown
Contributor

Fixes #602

The Folder combo stores ExportPresetOutputMode members as item data, but a persisted config round-trips through JSON as a plain string, so findData() never matched and the combo fell back to index 0. The panel showed "Subfolder of source" whatever was saved, and the next edit to any export field wrote that wrong mode back over the saved destination.

Normalize the row to the enum before lookup, falling back to ABSOLUTE for unknown values.

Testing

  • Two new cases in tests/test_export_settings_form.py: every mode restored from a plain string, and unknown values falling back to ABSOLUTE.
  • make all clean (2383 passed, 5 skipped).
  • Verified in the running app: the Export panel and the presets dialog both show the saved destination after opening an image.

🤖 Generated with Claude Code

https://claude.ai/code/session_01Nm64ZGh8un7ch3EanYv2K6

The Folder combo stores ExportPresetOutputMode members as item data, but a
persisted config round-trips through JSON as a plain string, so findData()
never matched and the combo fell back to index 0. The panel showed
"Subfolder of source" whatever was saved, and the next edit to any export
field wrote that wrong mode back over the saved destination.

Normalize the row to the enum before lookup, falling back to Absolute for
unknown values.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VcGpSk4mhUGCv7iuUejeTf
@marcinz606
marcinz606 merged commit 4772dcd into marcinz606:main Jul 22, 2026
1 check passed
@paulglover
paulglover deleted the fix/export-destination-mode-restore branch July 23, 2026 02:24
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.

Export panel and presets resets destination mode to "Absolute Path" or "Subfolder of source" when opening an image

2 participants