const QDate lastMonthDate = currentDate.addMonths(-1);
if (lastMonthDate.year() == modifiedDate.year() && lastMonthDate.month() == modifiedDate.month()) {
if (daysDistance == 1) {
- retString = i18nc("@title:group Date: %B is full month name in current locale, and %Y is full year number", "Yesterday (%B, %Y)");
+ retString = modifiedTime.toString(i18nc("@title:group Date: %B is full month name in current locale, and %Y is full year number", "Yesterday (%B, %Y)"));
} else if (daysDistance <= 7) {
retString = modifiedTime.toString(i18nc("@title:group The week day name: %A, %B is full month name in current locale, and %Y is full year number", "%A (%B, %Y)"));
} else if (daysDistance <= 7 * 2) {
retString = i18nc("@title:group Files and folders by permissions", "(User: %1) (Group: %2) (Others: %3)", user, group, others);
break;
- }
+ }
case KDirModel::Owner:
retString = item.user();
const quint32 rating = ratingForIndex(index);
retString = QString::number(rating);
break;
- }
+ }
case DolphinModel::Tags: {
retString = tagsForIndex(index);
break;
case KDirModel::Type:
- if (item.isDir())
+ if (item.isDir()) {
retVariant.clear(); // when sorting we want folders to be placed first
- else
+ } else {
retVariant = item.mimeComment();
+ }
break;
#ifdef HAVE_NEPOMUK