| 714 | } |
| 715 | |
| 716 | void ReadingListModel::reorderingChildren(QList<ReadingListItem *> children) |
| 717 | { |
| 718 | QList<qulonglong> childrenIds; |
| 719 | int i = 0; |
| 720 | for (auto *item : children) { |
| 721 | item->setOrdering(i++); |
| 722 | childrenIds << item->getId(); |
| 723 | } |
| 724 | QString connectionName = ""; |
| 725 | { |
| 726 | QSqlDatabase db = DataBaseManagement::loadDatabase(_databasePath); |
| 727 | DBHelper::reasignOrderToSublists(childrenIds, db); |
| 728 | connectionName = db.connectionName(); |
| 729 | } |
| 730 | QSqlDatabase::removeDatabase(connectionName); |
| 731 | } |
| 732 | |
| 733 | bool ReadingListModel::rowIsSpecialList(int row, const QModelIndex &parent) const |
| 734 | { |
nothing calls this directly
no test coverage detected