respect auto-expand policy when moving around with select next/previous item shortcuts in feeds list
This commit is contained in:
parent
94454dfc04
commit
a87e09d49a
@ -369,11 +369,6 @@ void FeedsView::openSelectedItemsInNewspaperMode() {
|
||||
void FeedsView::selectNextItem() {
|
||||
QModelIndex index_next = moveCursor(QAbstractItemView::CursorAction::MoveDown, Qt::KeyboardModifier::NoModifier);
|
||||
|
||||
while (m_proxyModel->hasChildren(index_next) && !isExpanded(index_next)) {
|
||||
expand(index_next);
|
||||
index_next = moveCursor(QAbstractItemView::CursorAction::MoveDown, Qt::KeyboardModifier::NoModifier);
|
||||
}
|
||||
|
||||
if (index_next.isValid()) {
|
||||
setCurrentIndex(index_next);
|
||||
scrollTo(index_next, QAbstractItemView::ScrollHint::EnsureVisible);
|
||||
@ -385,11 +380,6 @@ void FeedsView::selectNextItem() {
|
||||
void FeedsView::selectPreviousItem() {
|
||||
QModelIndex index_previous = moveCursor(QAbstractItemView::CursorAction::MoveUp, Qt::KeyboardModifier::NoModifier);
|
||||
|
||||
while (m_proxyModel->hasChildren(index_previous) && !isExpanded(index_previous)) {
|
||||
expand(index_previous);
|
||||
index_previous = moveCursor(QAbstractItemView::CursorAction::MoveUp, Qt::KeyboardModifier::NoModifier);
|
||||
}
|
||||
|
||||
if (index_previous.isValid()) {
|
||||
setCurrentIndex(index_previous);
|
||||
scrollTo(index_previous, QAbstractItemView::ScrollHint::EnsureVisible);
|
||||
|
Loading…
x
Reference in New Issue
Block a user