fix: add txt books to recent tab

This commit is contained in:
mrtnvgr 2026-01-24 09:07:28 +07:00
parent 3ce11f14ce
commit 54d6cba396
No known key found for this signature in database
GPG Key ID: 5B3379E981EF48B1

View File

@ -8,6 +8,7 @@
#include "CrossPointSettings.h"
#include "CrossPointState.h"
#include "MappedInputManager.h"
#include "RecentBooksStore.h"
#include "ScreenComponents.h"
#include "fontIds.h"
@ -55,9 +56,10 @@ void TxtReaderActivity::onEnter() {
txt->setupCacheDir();
// Save current txt as last opened file
// Save current txt as last opened file and add to recent books
APP_STATE.openEpubPath = txt->getPath();
APP_STATE.saveToFile();
RECENT_BOOKS.addBook(txt->getPath());
// Trigger first update
updateRequired = true;