Skip to content

Commit

Permalink
Fix Mac not scrolling to commit
Browse files Browse the repository at this point in the history
  • Loading branch information
francescmm committed Oct 6, 2024
1 parent a4f33ac commit 5449359
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/history/CommitHistoryView.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -176,16 +176,16 @@ void CommitHistoryView::focusOnCommit(const QString &goToSha)

if (mIsFiltering)
{
const auto sourceIndex = mProxyModel->sourceModel()->index(row, 0);
const auto sourceIndex = mProxyModel->sourceModel()->index(row, 1);
row = mProxyModel->mapFromSource(sourceIndex).row();
}

clearSelection();

const auto index = model()->index(row, 0);
const auto index = model()->index(row, 1);

setCurrentIndex(index);
scrollTo(currentIndex());
scrollTo(index);
}

QModelIndexList CommitHistoryView::selectedIndexes() const
Expand Down

0 comments on commit 5449359

Please sign in to comment.