mirror of
https://github.com/YACReader/yacreader
synced 2025-06-04 01:28:55 -04:00
commit
214ae69c79
@ -2,6 +2,11 @@
|
||||
|
||||
Version counting is based on semantic versioning (Major.Feature.Patch)
|
||||
|
||||
## 9.13.1
|
||||
|
||||
### YACReaderLibrary
|
||||
* Fix crash when dropping comics in sublists
|
||||
|
||||
## 9.13
|
||||
|
||||
### YACReaderLibrary
|
||||
|
@ -218,8 +218,13 @@ bool ReadingListModel::canDropMimeData(const QMimeData *data, Qt::DropAction act
|
||||
QByteArray rawData = data->data(YACReader::YACReaderLibrarSubReadingListMimeDataFormat);
|
||||
QDataStream in(&rawData, QIODevice::ReadOnly);
|
||||
in >> sublistsRows; // deserialize the list of indentifiers
|
||||
|
||||
if (sublistsRows.isEmpty())
|
||||
return false;
|
||||
|
||||
if (parent.row() != sublistsRows.at(0).second)
|
||||
return false;
|
||||
|
||||
return data->formats().contains(YACReader::YACReaderLibrarSubReadingListMimeDataFormat);
|
||||
}
|
||||
}
|
||||
|
@ -1363,10 +1363,10 @@ void DBHelper::insertComicsInFavorites(const QList<ComicDB> &comicsList, QSqlDat
|
||||
|
||||
void DBHelper::insertComicsInLabel(const QList<ComicDB> &comicsList, qulonglong labelId, QSqlDatabase &db)
|
||||
{
|
||||
QSqlQuery getNumComicsInFavoritesQuery(QString("SELECT count(*) FROM comic_label WHERE label_id = %1;").arg(labelId), db);
|
||||
getNumComicsInFavoritesQuery.next();
|
||||
QSqlQuery getNumComics(QString("SELECT count(*) FROM comic_label WHERE label_id = %1;").arg(labelId), db);
|
||||
getNumComics.next();
|
||||
|
||||
int numComics = getNumComicsInFavoritesQuery.value(0).toInt();
|
||||
int numComics = getNumComics.value(0).toInt();
|
||||
|
||||
db.transaction();
|
||||
|
||||
@ -1388,10 +1388,10 @@ void DBHelper::insertComicsInLabel(const QList<ComicDB> &comicsList, qulonglong
|
||||
|
||||
void DBHelper::insertComicsInReadingList(const QList<ComicDB> &comicsList, qulonglong readingListId, QSqlDatabase &db)
|
||||
{
|
||||
QSqlQuery getNumComicsInFavoritesQuery("SELECT count(*) FROM comic_reading_list;", db);
|
||||
getNumComicsInFavoritesQuery.next();
|
||||
QSqlQuery getNumComics("SELECT count(*) FROM comic_reading_list;", db);
|
||||
getNumComics.next();
|
||||
|
||||
int numComics = getNumComicsInFavoritesQuery.value(0).toInt();
|
||||
int numComics = getNumComics.value(0).toInt();
|
||||
|
||||
db.transaction();
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user