-
-
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
Library controller navigation fixes & enhancements #2333
Conversation
7f0bb35
to
4f9b050
Compare
6f45f79
to
e9fd03c
Compare
0b80598
to
a1e996b
Compare
a1e996b
to
185984e
Compare
if (m_pLibraryWidget->getActiveView()->hasFocus()) { | ||
return true; | ||
} | ||
return false; |
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.
maybe this doesn't need to be a separate function, until now we need it only twice here.
} else { | ||
// Otherwise toggle the sidebar item expanded state | ||
slotToggleSelectedSidebarItem(v); | ||
} |
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.
unchanged
// Clear the search if the searchbox has focus | ||
if (m_pSearchbox->hasFocus()) { | ||
return emit(clearSearch()); | ||
} |
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.
unchanged
After GoToItem > |
I don't think that's safe to guess. Clearing the search from a controller then reaching to the keyboard to type seems like a reasonable thing to do IMO. |
Any objections? |
I attempt to clean up my outdated previous PR to clear search via controllers with [Library],GoToItem, as well as some small improvements for library controller navigation.
reworked and rebased since noone reviewed it anyways so far
I hope the commits are easy to review because I think this solves some issues with basic Library navigation that would ease the library/controller UX in 2.3
https://bugs.launchpad.net/mixxx/+bug/1840541
don't allow to focus Library feature buttons
... in Recording, AutoDJ, Analysis, Hidden or Missing neither with
Tab
key on keyboard nor[Library]MoveFocus...
to always see the focus indicating border on the sidebar or tracks table.There's no point in having those focused as there's no way to trigger them, neither from keyboard or controllers. For AutoDJ and Recording there are keyboard shortcuts.
fix hasFocus()
... in DlgRecording, DlgAutoDJ, DlgAnalysis, DlgHidden and DlgMissing to prevent 'refocus Library' calls there before issuing a move/scroll command.
Prevent focus from getting stuck at Clear button
In master, the focus can be moved to the Clear button with
[Library],MoveFocus[Backward, Forward]
(when there is an active search). Then,MoveFocusForward
would do nothing because behind the scenes library control tests if the sidebar or tracks table have focus; if false it would try to re-focus the tracks table: focus the sidebar > emulate Tab > then send the MoveFocus Tab = we end up at the Clear button again. WithMoveFocus, -1
it would jump between sidebar and Clear button.Now, the focus controls always send a Tab key no matter which widget has focus.
Clear Search from controller
Clear the seach with
[Library],GoToItem
when either the searchbox or the Clear button has focus.ToDo