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

"misc" view now shows the model state, of the track use of master pitch #3753

Merged
merged 3 commits into from Aug 15, 2017

Conversation

@serdnab
Copy link
Contributor

@serdnab serdnab commented Aug 6, 2017

Fix for #2612.
When an already created instance of InstrumentTrackWindow is used, the master pitch GroupBox isn't refreshed.
Now, if this is the case, when modelChanged() is invoked, the refresh is done.

@PhysSong PhysSong requested a review from zonkmachine Aug 6, 2017
@PhysSong
Copy link
Member

@PhysSong PhysSong commented Aug 6, 2017

Good observation! I haven't tested it yet, but It should be work.

@gi0e5b06
Copy link

@gi0e5b06 gi0e5b06 commented Aug 6, 2017

getPitchGroupBox() should be renamed pitchGroupBox(), according to Qt and Lmms coventions.
Use the read accessor and not directly the field:
m_miscView->getPitchGroupBox()->setModel(&m_track->m_useMasterPitchModel);
should be:
m_miscView->pitchGroupBox()->setModel(m_track.useMasterPitchModel());
wgich requires to have the models mapped as properties, like volume.

BTW, thanks for the fix. If you spend a bit more time on refactoring the models/properties for the Track class, that would be great.

@Umcaruje
Copy link
Member

@Umcaruje Umcaruje commented Aug 7, 2017

I tested this and it works like a charm 👍 But @gi0e5b06 is right it seems inconsistent with the rest of the software so that'd need to change before a merge.

@PhysSong
Copy link
Member

@PhysSong PhysSong commented Aug 8, 2017

I think @gi0e5b06 is right, too.

getPitchGroupBox() should be renamed pitchGroupBox()

Yes, it's our convention.

Use the read accessor and not directly the field

It is recommended, but I think it's not necessary.

@Umcaruje Umcaruje added this to the 1.2.0 milestone Aug 8, 2017
@zonkmachine zonkmachine removed their request for review Aug 10, 2017
@serdnab
Copy link
Contributor Author

@serdnab serdnab commented Aug 10, 2017

getPitchGroupBox() should be renamed pitchGroupBox()

Yes, it's our convention.

Addressed

@@ -72,7 +72,7 @@ class InstrumentMiscView : public QWidget
InstrumentMiscView( InstrumentTrack *it, QWidget* parent );
~InstrumentMiscView();

GroupBox * getPitchGroupBox()
GroupBox * PitchGroupBox()

This comment has been minimized.

@zonkmachine

zonkmachine Aug 10, 2017
Member

Lower case here: PitchGroupBox() -> pitchGroupBox()

This comment has been minimized.

@PhysSong
Copy link
Member

@PhysSong PhysSong commented Aug 12, 2017

@serdnab
Copy link
Contributor Author

@serdnab serdnab commented Aug 13, 2017

Done

@zonkmachine
Copy link
Member

@zonkmachine zonkmachine commented Aug 15, 2017

Tested! This fixes the issue.
Merge?

@zonkmachine zonkmachine merged commit 153ab37 into LMMS:master Aug 15, 2017
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
zonkmachine added a commit that referenced this pull request Aug 16, 2017
…ch (#3753)

[cherry-picked from master]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

5 participants
You can’t perform that action at this time.