Add setting to hide the "Continue Reading..." banner from the home view.

This commit is contained in:
Luis Ángel San Martín
2024-12-28 14:36:42 +01:00
parent e5eda8e461
commit f5eb81dcac
11 changed files with 44 additions and 19 deletions

View File

@ -163,7 +163,8 @@ FolderContentView::FolderContentView(QAction *toogleRecentVisibilityAction, QWid
ctxt->setContextProperty("comicsList", comicModel.get());
ctxt->setContextProperty("foldersList", folderModel);
ctxt->setContextProperty("showCurrentComic", QVariant(false));
auto showContinueReading = settings->value(DISPLAY_GLOBAL_CONTINUE_READING_IN_GRID_VIEW, true).toBool();
ctxt->setContextProperty("showContinueReading", QVariant(showContinueReading));
ctxt->setContextProperty("openHelper", this);
ctxt->setContextProperty("dropManager", this);
@ -229,6 +230,14 @@ void FolderContentView::setRecentRange(int days)
folderModel->setRecentRange(days);
}
void FolderContentView::updateSettings()
{
QQmlContext *ctxt = view->rootContext();
auto showContinueReading = settings->value(DISPLAY_GLOBAL_CONTINUE_READING_IN_GRID_VIEW, true).toBool();
ctxt->setContextProperty("showContinueReading", QVariant(showContinueReading));
}
void FolderContentView::openFolder(int index)
{
emit subfolderSelected(this->parent, index);