mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-11-28 10:31:13 -05:00
Add keyboard shortcut to "Jump to Group" from search results (#12225)
* Add Ctrl+Shift+J keyboard shortcut for "Jump to Group" from search results --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: Jonathan White <support@dmapps.us>
This commit is contained in:
parent
41da5b2127
commit
83d1003ec2
3 changed files with 19 additions and 2 deletions
|
|
@ -36,8 +36,9 @@ kbd:[Ctrl + E]
|
||||||
|Copy Password and TOTP | kbd:[Ctrl + Y]
|
|Copy Password and TOTP | kbd:[Ctrl + Y]
|
||||||
|Show TOTP | kbd:[Ctrl + Shift + T]
|
|Show TOTP | kbd:[Ctrl + Shift + T]
|
||||||
|Trigger AutoType | kbd:[Ctrl + Shift + V]
|
|Trigger AutoType | kbd:[Ctrl + Shift + V]
|
||||||
|Add key to SSH Agent | kbd:[Ctrl + H]
|
|Add key to SSH Agent | kbd:[Ctrl + H]
|
||||||
|Remove key from SSH Agent | kbd:[Ctrl + Shift + H]
|
|Remove key from SSH Agent | kbd:[Ctrl + Shift + H]
|
||||||
|
|Jump to Group (from search) | kbd:[Ctrl + Shift + J]
|
||||||
|Move entry up (if unsorted) | kbd:[Ctrl + Alt + Up]
|
|Move entry up (if unsorted) | kbd:[Ctrl + Alt + Up]
|
||||||
|Move entry down (if unsorted) | kbd:[Ctrl + Alt + Down]
|
|Move entry down (if unsorted) | kbd:[Ctrl + Alt + Down]
|
||||||
|Sort Groups A-Z | kbd:[Ctrl + Down]
|
|Sort Groups A-Z | kbd:[Ctrl + Down]
|
||||||
|
|
|
||||||
|
|
@ -95,6 +95,7 @@ EntryView::EntryView(QWidget* parent)
|
||||||
});
|
});
|
||||||
|
|
||||||
new QShortcut(Qt::CTRL + Qt::Key_F10, this, SLOT(contextMenuShortcutPressed()), nullptr, Qt::WidgetShortcut);
|
new QShortcut(Qt::CTRL + Qt::Key_F10, this, SLOT(contextMenuShortcutPressed()), nullptr, Qt::WidgetShortcut);
|
||||||
|
new QShortcut(Qt::CTRL + Qt::SHIFT + Qt::Key_J, this, SLOT(jumpToGroupShortcut()), nullptr, Qt::WidgetShortcut);
|
||||||
|
|
||||||
resetViewToDefaults();
|
resetViewToDefaults();
|
||||||
|
|
||||||
|
|
@ -595,3 +596,17 @@ bool EntryView::isColumnHidden(int logicalIndex)
|
||||||
{
|
{
|
||||||
return header()->isSectionHidden(logicalIndex) || header()->sectionSize(logicalIndex) == 0;
|
return header()->isSectionHidden(logicalIndex) || header()->sectionSize(logicalIndex) == 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void EntryView::jumpToGroupShortcut()
|
||||||
|
{
|
||||||
|
// Only allow jump to group in search mode
|
||||||
|
if (!inSearchMode()) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
auto entry = currentEntry();
|
||||||
|
if (entry) {
|
||||||
|
// Emit the entryActivated signal with ParentGroup column to trigger jump to group
|
||||||
|
emit entryActivated(entry, EntryModel::ParentGroup);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -72,6 +72,7 @@ private slots:
|
||||||
void resetViewToDefaults();
|
void resetViewToDefaults();
|
||||||
void contextMenuShortcutPressed();
|
void contextMenuShortcutPressed();
|
||||||
void sortIndicatorChanged(int logicalIndex, Qt::SortOrder order);
|
void sortIndicatorChanged(int logicalIndex, Qt::SortOrder order);
|
||||||
|
void jumpToGroupShortcut();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void resetFixedColumns();
|
void resetFixedColumns();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue