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

convert as many "enum" as possible to "enum class", and make them ": char" in the due course #6 #1005

Merged
merged 23 commits into from
Jun 26, 2014

Conversation

Jojo-Schmitz
Copy link
Contributor

Follow up of PR #914, #927, #935, #936 and #946
Several enum types are "enum class" (i.e. typesafe C++ enums), several others are not.
Also making them ": char" should reduce the size of structures using them.

Some (at least those used in Q_ENUMS()) need to get moved inside a class, in order to be available to the plugin framework.
And simplify some ot the enum names to not have the class names as part of the enum Name.

@Jojo-Schmitz
Copy link
Contributor Author

@wschweer : was it SymId that should get changed from short back to int or SegmentType? Or both?

@lasconic
Copy link
Contributor

I would do both. Any reason why SegmentType couldn't get the same treatment?

@Jojo-Schmitz
Copy link
Contributor Author

No real reason, I just though it had been SymId only, then I realized that in the last PR it was SegmentType.
As SegmentType is exposed to the plugin framework it'd need to get move to Segment::Type too...

@Jojo-Schmitz
Copy link
Contributor Author

Where to move Direction and DirectionH? They are used for the plugin framework in class Note. Move them there? Or is there some better place (class MScore?) or better method? Direction is also used (for the plugin framework) in class SlurTie.
Other than that I'm done with this PR and deem it ready for merge ;-)

@wschweer
Copy link
Contributor

Direction and DirectionH should be in class MScore.

@Jojo-Schmitz
Copy link
Contributor Author

OK. Can't we combine them into one? Or rename Direction to DirectionV to make the difference more obvious?

@Jojo-Schmitz
Copy link
Contributor Author

oops, rebase needed, clash with 830c9f0.
And another, due to conflict with f3caba7.
Every single commit before passed Travis with flying colors...

needed to make it available to the Plugin framework
the memory saved is not worth the performance penalty
needed to make it available to the Plugin framework
needed to make it available to the Plugin framework
needed to make it available to the plugin framework
and the memory saved is not worth the performance penalty
and register Hairpin::Type, FiguredBassItem::ContLine and
Lyrics::Syllabic, which seemd missing.
Also fix registration of Element::Type and Segment::Type to what they
had been before.
needed to make it available to the plugin framework
needed to make it available to the plugin framework
needed to make it available to the plugin framework
needed to make it available to the plugin framework
needed to make it available to the plugin framework
needed to make it available to the plugin framework
needed to make it available to the plugin framework
needed to make it available to the plugin framework
and expose it to the plugin framwork, read-only for  now, as we don't
(yet?) have an undo method for it
needed to make them available to the plugin framework
wschweer added a commit that referenced this pull request Jun 26, 2014
convert as many "enum" as possible to "enum class", and make them ": char" in the due course #6
@wschweer wschweer merged commit 9bc97ac into musescore:master Jun 26, 2014
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.

3 participants