-
-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Track operations fixes and other stuff. #3878
Conversation
I can only approve (as I have made the same changes in my PR, including the TODO item). |
Could you commit the fix for the TODO item here? |
It's here: https://github.com/gi0e5b06/lmms/blob/master/src/core/Track.cpp |
Also I like the lines 1876-1880: https://github.com/gi0e5b06/lmms/blob/86a54872b9d00fbfc338f1864a903bf4d690f962/src/core/Track.cpp#L1876
It draws a small red line on the left border when you're moving the track. |
Note, this prevents the previous behavior of dragging a track by "any random empty part of the track label" behavior that had been working previously. Since no one has made a UX argument against this, and it actually fixes the drag handle, merging. If you want the old way, you'll have to argue it back. From a UI perspective we really don't allow rearranging of items like this in any other part of the software except the pattern editors, which aren't UI input elements. Although I personally prefer a "long hold, then drag" like most modern software uses, that should be filed as a new feature. |
@@ -2713,6 +2710,12 @@ void TrackView::dropEvent( QDropEvent * de ) | |||
*/ | |||
void TrackView::mousePressEvent( QMouseEvent * me ) | |||
{ | |||
if( me->x()>10 ) // 10 = The width of the grip + 2 pixels to the left and right. |
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.
This breaks horizontal track resizing. I think this check should be moved to below.
@@ -2745,7 +2748,7 @@ void TrackView::mousePressEvent( QMouseEvent * me ) | |||
{ | |||
m_action = MoveTrack; |
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.
To here.
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.
Tested. Fixes the issue as expected.
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.
Direct commit or PR?
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.
Direct commit looks fine.
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.
Done via e8debf9. 👍
Fixes a regression from PR LMMS#3878 that broke horizontal track resizing.
Fixes #3592 and other stuff.
Changes:
• Limit the ability of moving a track to its move grip.
• Clicking the move grip of a track doesn't hide the track's mute and options buttons.
• Clicking the move grip of a track changes the move grip's image to one with white squares instead of gray.
• Changed the cursor shape that shows when moving tracks to be vertical.
• Improved the position and padding of the gear image.
• Removed the
trackop_c.png
andtrackop_h.png
files and some of their related code in thestyle.css
file of the default theme.