Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Followup for PR #6935, that included a bug. #6987

Merged
merged 1 commit into from
Dec 2, 2020

Conversation

ecstrema
Copy link
Contributor

@ecstrema ecstrema commented Dec 1, 2020

MeasureNumbers and MMRestRanges were deleted in measure::remove,
which caused a crash when undoing the deletion of these elements.

Although this may look as a big refactoring for the small issue it solves, it includes a refactoring of the measure number class into a measureNumberBase class, which MMRestRange, as well as MeasureNumber, inherit. So in fact there's only code moving here.

Previously:   TextBase->MeasureNumber->MMRestRange
WIth this PR: TextBase->MeasureNumberBase->MeasureNumber
              							 ->MMRestRange

This refactoring should lead to a less errorprone implementation.

  • I signed CLA
  • I made sure the code in the PR follows the coding rules
  • I made sure the code compiles on my machine
  • I made sure there are no unnecessary changes in the code
  • I made sure the title of the PR reflects the core meaning of the issue you are solving
  • I made sure the commit message(s) contain a description and answer the question "Why do those changes fix that particular issue?" or "Why are those changes really necessary as improvements?"
  • I made sure the commit message title starts with "fix #424242:" if there is a related issue
  • I created the test (mtest, vtest, script test) to verify the changes I made

libmscore/measurenumberbase.cpp Outdated Show resolved Hide resolved
libmscore/measurenumberbase.cpp Outdated Show resolved Hide resolved
`MeasureNumber`s and `MMRestRange`s were `delete`d in `measure::remove`,
which caused a crash when undoing the deletion of these elements.
@ecstrema
Copy link
Contributor Author

ecstrema commented Dec 1, 2020

updated license and removed unused includes

@vpereverzev vpereverzev merged commit 01a2b7f into musescore:3.x Dec 2, 2020
@ecstrema ecstrema deleted the mn-read branch December 8, 2020 21:45
igorkorsukov added a commit to igorkorsukov/MuseScore that referenced this pull request Feb 4, 2021
igorkorsukov added a commit to igorkorsukov/MuseScore that referenced this pull request Feb 4, 2021
igorkorsukov added a commit to igorkorsukov/MuseScore that referenced this pull request Feb 4, 2021
igorkorsukov added a commit to igorkorsukov/MuseScore that referenced this pull request Feb 4, 2021
…tion to show measure number range at mmrests
vpereverzev pushed a commit that referenced this pull request Feb 4, 2021
igorkorsukov added a commit to igorkorsukov/MuseScore that referenced this pull request Feb 4, 2021
…tion to show measure number range at mmrests
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.

2 participants