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

Add the ability to close score tab by clicking middle button (fix #27371) #5871

Merged
merged 1 commit into from
Apr 21, 2020

Conversation

Harmoniker1
Copy link
Contributor

mscore/scoretab.cpp Outdated Show resolved Hide resolved
mscore/scoretab.h Outdated Show resolved Hide resolved
mscore/scoretab.cpp Outdated Show resolved Hide resolved
@Jojo-Schmitz
Copy link
Contributor

Somehow Travis got stuck on this. Or rather GitHub lost connection to Travis

@Harmoniker1
Copy link
Contributor Author

Will push again later.

@Harmoniker1 Harmoniker1 force-pushed the tab-middle-button branch 4 times, most recently from dc8314e to 403070c Compare April 1, 2020 08:15
mscore/scoretab.cpp Outdated Show resolved Hide resolved
@Harmoniker1 Harmoniker1 force-pushed the tab-middle-button branch 2 times, most recently from ccb2a3e to 281f663 Compare April 5, 2020 22:06
mscore/scoretab.h Outdated Show resolved Hide resolved
{
QTabBar::mouseReleaseEvent(e);
if (e->button() == Qt::MiddleButton) {
if (tabAt(e->pos()) == _middleClickedTab)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be nice to have a gesture recognizer that would detect actions and already respond to them. This is not a suggestion to do in this PR, just thoughts.

MsTabBar::MsTabBar() {

_gestureRecognizer = new GestureRecognizer(this); <- setting event filter
connect(_gestureRecognizer, &GestureRecognizer::middleClicked, this, &MsTabBar::onMiddleClicked);
}

@anatoly-os anatoly-os merged commit 764db85 into musescore:master Apr 21, 2020
@Harmoniker1 Harmoniker1 deleted the tab-middle-button branch April 21, 2020 13:48
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.

6 participants