Address review

This commit is contained in:
Howard-C 2020-04-14 16:49:23 +08:00
parent 10ccdaa9ce
commit 70e41448a9
2 changed files with 7 additions and 10 deletions

View file

@ -53,17 +53,14 @@ Tremolo::Tremolo(Score* score)
: Element(score, ElementFlag::MOVABLE)
{
initElementStyle(&tremoloStyle);
setTremoloType(TremoloType::R8);
_chord1 = 0;
_chord2 = 0;
}
Tremolo::Tremolo(const Tremolo& t)
: Element(t)
{
setTremoloType(t.tremoloType());
_chord1 = t.chord1();
_chord2 = t.chord2();
_chord1 = t.chord1();
_chord2 = t.chord2();
_durationType = t._durationType;
}

View file

@ -41,15 +41,15 @@ enum class TremoloBeamStyle : signed char {
//---------------------------------------------------------
class Tremolo final : public Element {
TremoloType _tremoloType;
Chord* _chord1;
Chord* _chord2;
TremoloType _tremoloType { TremoloType::R8 };
Chord* _chord1 { nullptr };
Chord* _chord2 { nullptr };
TDuration _durationType;
QPainterPath path;
int _lines; // derived from _subtype
TremoloPlacement _tremoloPlacement;
TremoloBeamStyle _beamStyle;
TremoloPlacement _tremoloPlacement { TremoloPlacement::DEFAULT };
TremoloBeamStyle _beamStyle { TremoloBeamStyle::DEFAULT };
QPainterPath basePath() const;
void computeShape();