Card-Forge / Card-Forge/forge

Draft and sealed deck editors show, and save under, the previous editor's deck name

Open
#11,893 0 comments 0 reactions 1 assignee Claimed by @leriomaggio View on GitHub
Dominant language
Java
Stars
2.7k
Forks
1.1k
Avg merge
1d 1h
Merged PRs (30d)
163

Description

**Describe the bug**

Switching into the Draft or Sealed deck editor leaves the deck name from whichever
editor was open before in the title box. Saving then writes the deck under that
name, and the box is disabled in those editors so it cannot be corrected first.

**To Reproduce**
1. Open a draft deck editor.
2. Switch to the Deck Editor tab.
3. Switch back to the draft deck editor.
4. The title box shows the constructed deck's name, not the draft's.

**Expected behavior**

The title box shows the deck the current editor actually has open.

**Desktop**
- OS: macOS
- Version: 2.0.15-SNAPSHOT, master at c8199da

**Additional context**

`VCurrentDeck` is one panel shared by every editor, and
`DeckController.updateCaptions` is the only thing that writes its title box.
`CEditorConstructed.update()` ends with `refreshModel()`, which reaches it.
`CEditorLimited.update()` does not, so the box keeps its previous contents.
`SEditorIO.saveDeck` takes the name to save under straight from that box.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.