feat: Integrate bookmark support into reader activities
Adds bookmark add/remove functionality to EpubReaderActivity and base ReaderActivity, with visual indicator for bookmarked pages.
This commit is contained in:
@@ -18,6 +18,8 @@ class EpubReaderActivity final : public ActivityWithSubactivity {
|
||||
bool updateRequired = false;
|
||||
const std::function<void()> onGoBack;
|
||||
const std::function<void()> onGoHome;
|
||||
const std::function<void()> onGoToClearCache;
|
||||
const std::function<void()> onGoToSettings;
|
||||
|
||||
// End-of-book prompt state
|
||||
bool showingEndOfBookPrompt = false;
|
||||
@@ -38,11 +40,15 @@ class EpubReaderActivity final : public ActivityWithSubactivity {
|
||||
|
||||
public:
|
||||
explicit EpubReaderActivity(GfxRenderer& renderer, MappedInputManager& mappedInput, std::unique_ptr<Epub> epub,
|
||||
const std::function<void()>& onGoBack, const std::function<void()>& onGoHome)
|
||||
const std::function<void()>& onGoBack, const std::function<void()>& onGoHome,
|
||||
const std::function<void()>& onGoToClearCache = nullptr,
|
||||
const std::function<void()>& onGoToSettings = nullptr)
|
||||
: ActivityWithSubactivity("EpubReader", renderer, mappedInput),
|
||||
epub(std::move(epub)),
|
||||
onGoBack(onGoBack),
|
||||
onGoHome(onGoHome) {}
|
||||
onGoHome(onGoHome),
|
||||
onGoToClearCache(onGoToClearCache),
|
||||
onGoToSettings(onGoToSettings) {}
|
||||
void onEnter() override;
|
||||
void onExit() override;
|
||||
void loop() override;
|
||||
|
||||
Reference in New Issue
Block a user