-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Cue context menu for scrolling waveform #2783
Cue context menu for scrolling waveform #2783
Conversation
@Be-ing Should this really be added to 2.3? |
Should I rebase to mixxxdj:2.3 or master? |
@hacksdump Not sure. I just saw the unrelated commits and then later noticed that @Be-ing retargeted the PR to 2.3 which might have caused them. Since this is a new "feature" master would be more appropriate imo. |
Yes, new feature=master. I have changed the target branch. |
This was already planned to go to 2.3 before cutting the 2.3 branch. |
We need to get used to the new dead line based release strategy. 2.2 was release 11 Jan 2019. If we would have stopped to add features to 2.3, it would have been release in Juli 2019. Now we would have had released 2.4, a 2.5 beta and we where considering shiny new features for 2.6. |
I think we should have a discussion about why 2.3 took so long. But this PR is not the place for that. |
Try to rebase onto 2.3. If this works without conflicts we could decide after the review if it is safe to merge into 2.3. |
Good work! The color change when hovering the mark is a nice detail that makes this feature easier to discover. There are a few minor ways to make the code a little easier to understand. We can use the same general approach to add right click menus for beats, downbeats, phrases, and section markers. Hopefully we can reuse some of this code too. |
Code is almost ready, only some minor comments. This feature would be a nice addition for 2.3 to complete the cue improvements and extensions. Let's keep 2.3 as the target. |
wwaveformviewer.h seems to be missing an #include directive? The SCons builds fail. |
This functionality to find if a point lies in/near a cue marker, beat, downbeat, phrase marker will be quite common. Can this be abstracted to a new parent class? |
Seems like a good idea to me. |
i.e. |
Or |
22b1915
to
c8e7506
Compare
Thanks. I just deleted other commits. Would have been easier to just rebase to my first commit. Fixed the scons build as well. Let's wait for CI builds. |
Of course, both ^ and ~1 are equivalent. |
Works, nice feature 👍 |
There is a merge conflict since #2663 was merged. Fix that and also please use the new utility function introduced in that PR for showing CueMenuPopup in the scrolling waveform. |
I have merged #2663. A minor merge conflict needs to be resolved and we could use mixxx::widgethelper::mapPopupToScreen() for this new popup menu. |
Race condition while commenting on this PR ;) |
Writing this explicitly for every child of QMenu seems cumbersome. Every menu needs to be within mixxx boundaries. For this PR, I will just change |
src/widget/wwaveformviewer.cpp
Outdated
m_pCueMenuPopup->popup(event->globalPos()); | ||
QPoint cueMenuTopLeft = mixxx::widgethelper::mapPopupToScreen( | ||
windowHandle()->screen()->size(), | ||
event->globalPos(), | ||
m_pCueMenuPopup->size()); | ||
m_pCueMenuPopup->popup(cueMenuTopLeft); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You don't need to bother going back and changing this commit, but for the future please make merge commits the bare minimum required to resolve conflicts and get it to build and run, then add new changes in following commits.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Got that. Shouldn't have combined it into the merge resolution commit. Will keep that in mind.
Pre-commit warnings are unrelated. LGTM. Do we agree to merge this into 2.3? |
Great. Thank you for contributing these UX improvements, Harshit! Working on this PR was a pleasure and also a constructive collaboration among everyone involved. |
Adds context menu to hot cues on the scrolling waveform just like WOverview. Right-click on the label to invoke the context menu.
TODOs:
Disallow opening context menu when a track is playing.
Open context menu when right-clicking in the vicinity of marker line.
Highlight cue mark on hover.