Commit 648a496e authored by Marc Mutz's avatar Marc Mutz
Browse files

QFileSystemModel: avoid sibling() calls


...by allowing to pass the column to the Private::index() overloads.

Because Private::index() always returns an index in column 0,
callers that needed a different column used QModelIndex::sibling()
to adjust the column of the returned index. But that calls
QAIM::sibling(), which calls both QFSM::index() and ::parent().

Simply allowing to pass the column number instead of hard-coding
0 avoids that heavy detour.

Change-Id: I8895b3d102d576ba291333cf61075b7263f96b9d
Reviewed-by: default avatarFriedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: default avatarDavid Faure <david.faure@kdab.com>
parent ce7fb157
No related merge requests found
Showing with 6 additions and 11 deletions
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment