Cabana: fix wrong hardcoded column index (#26392)

fix wrong column count
old-commit-hash: ea5587d1d14e01b7a2aeae34f8abc73886699519
This commit is contained in:
Dean Lee
2022-11-07 03:03:57 +08:00
committed by GitHub
parent 1bc0166499
commit 650a6a921c
+1 -1
View File
@@ -224,7 +224,7 @@ void MessageListModel::updateState(bool sort) {
changePersistentIndex(idx, index(std::distance(msgs.begin(), it), idx.column()));
}
}
emit dataChanged(index(0, 0), index(msgs.size() - 1, 3), {Qt::DisplayRole});
emit dataChanged(index(0, 0), index(msgs.size() - 1, columnCount() - 1), {Qt::DisplayRole});
}
}