]> cloud.milkyroute.net Git - dolphin.git/commitdiff
Corrected description of applySortRole()
authorZakhar Afonin <zakharafoniam@gmail.com>
Sat, 22 Jun 2024 10:39:24 +0000 (13:39 +0300)
committerZakhar Afonin <zakharafoniam@gmail.com>
Sat, 22 Jun 2024 10:39:24 +0000 (13:39 +0300)
src/kitemviews/kfileitemmodelrolesupdater.cpp
src/kitemviews/kfileitemmodelrolesupdater.h

index 0012e99c1c2f1c5bea81426ff65a630e9d3215d7..3828f0979cbb98576dbcc7a67015fe01c8dfd3b8 100644 (file)
@@ -1218,7 +1218,6 @@ void KFileItemModelRolesUpdater::applySortRole(int index)
     QHash<QByteArray, QVariant> data;
     const KFileItem item = m_model->fileItem(index);
 
     QHash<QByteArray, QVariant> data;
     const KFileItem item = m_model->fileItem(index);
 
-    // Despite the name, this handles both sorting and grouping, as they happen at the same time (resorting items).
     if (m_model->sortRole() == "type" || m_model->groupRole() == "type") {
         if (!item.isMimeTypeKnown()) {
             item.determineMimeType();
     if (m_model->sortRole() == "type" || m_model->groupRole() == "type") {
         if (!item.isMimeTypeKnown()) {
             item.determineMimeType();
index aa9ca5fc0e325591f5562815f53d8c614db4021c..df3a9422622b5a3c68d166de675b30e6aee648f2 100644 (file)
@@ -315,6 +315,8 @@ private:
 
     /**
      * Resolves the sort role of the item and applies it to the model.
 
     /**
      * Resolves the sort role of the item and applies it to the model.
+     * Despite the name, this handles both sorting and grouping, as 
+     * regrouping never happens without resorting at the same time.
      */
     void applySortRole(int index);
 
      */
     void applySortRole(int index);