mirror of
https://github.com/YACReader/yacreader
synced 2025-05-28 03:10:27 -04:00
Update the current comic model when the server gets a syn request
Sadly the grid view resets its scroll to origin. Not sure if it is going to bother anyone, we'll see.
This commit is contained in:
parent
928afa4675
commit
e8f31b39ee
@ -896,6 +896,27 @@ void ComicModel::reloadContinueReading()
|
||||
setupReadingModelData(_databasePath);
|
||||
}
|
||||
|
||||
void ComicModel::reload()
|
||||
{
|
||||
switch (mode) {
|
||||
case Folder:
|
||||
setupFolderModelData(sourceId, _databasePath);
|
||||
break;
|
||||
case Favorites:
|
||||
setupFavoritesModelData(_databasePath);
|
||||
break;
|
||||
case Reading:
|
||||
setupReadingModelData(_databasePath);
|
||||
break;
|
||||
case Label:
|
||||
setupLabelModelData(sourceId, _databasePath);
|
||||
break;
|
||||
case ReadingList:
|
||||
setupReadingListModelData(sourceId, _databasePath);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void ComicModel::remove(int row)
|
||||
{
|
||||
removeInTransaction(row);
|
||||
|
@ -112,6 +112,7 @@ public:
|
||||
// void remove(ComicDB * comic, int row);
|
||||
void removeInTransaction(int row);
|
||||
void reloadContinueReading();
|
||||
void reload();
|
||||
void reload(const ComicDB &comic);
|
||||
void resetComicRating(const QModelIndex &mi);
|
||||
|
||||
|
@ -2812,6 +2812,7 @@ void LibraryWindow::importLibraryPackage()
|
||||
|
||||
void LibraryWindow::updateViewsOnClientSync()
|
||||
{
|
||||
comicsModel->reload();
|
||||
contentViewsManager->updateCurrentComicView();
|
||||
contentViewsManager->updateContinueReadingView();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user