LiveSplit / LiveSplit/LiveSplit
Hitting Cancel in RunEditorDialog always destroys and re-creates Autosplitters, even if Run and runCopy are exactly the same.
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 1.9k
- Forks
- 815
- Avg merge
- 4d 17h
- Merged PRs (30d)
- 3
Description
This is in `TimerForm`'s `EditSplits()`. Here, the `RunEditorDialog` is created. And `if (result == DialogResult.Cancel)`, eventually `SetRun(runCopy)` is called, regardless of if Run differs from `runCopy`. `SetRun` deactivates and recreates the autosplitting component.
Outside of ongoing runs, this behavior is fine. But if it happens during a run, this is potentially catastrophic for the autosplitter and LS run data.
The basic user story example:
* User starts a run
* At some point (say, during an unskippable cutscene), user opens `RunEditorDialog` to check their Splits or component's Settings.
* User makes no changes, but verifies everything looks good!
* User eventually clicks "Cancel" to close `RunEditorDialog`.
* All sense of state is lost as the Autosplitter is destroyed and created by `SetRun(runCopy)`.
* This can cause erroneous behavior, breaking part or all of the autosplitter's functionality, depending on its implementation.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in TimerForm's EditSplits(), where RunEditorDialog is created and Cancel eventually calls SetRun(runCopy). Trace how SetRun deactivates and recreates the autosplitting component, then verify the unchanged-run Cancel path avoids that recreation while edits still update the run correctly.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- desktop
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 55/100