Files
crosspoint-reader-mod/chat-summaries/2026-02-13_merge-upstream-summary.md
cottongin dfbc931c14 mod: Phase 1 - bring forward mod-exclusive files with ActivityManager migration
Brings ~55 mod-exclusive files to the upstream-based mod/master-resync branch:

Activities (migrated to new ActivityManager pattern):
- Clock/Time: SetTimeActivity, SetTimezoneOffsetActivity, NtpSyncActivity
- Dictionary: DictionaryDefinitionActivity, DictionarySuggestionsActivity,
  DictionaryWordSelectActivity, LookedUpWordsActivity
- Bookmark: EpubReaderBookmarkSelectionActivity
- Book management: BookManageMenuActivity, EndOfBookMenuActivity
- OPDS: OpdsServerListActivity, OpdsSettingsActivity
- Utility: DirectoryPickerActivity, NumericStepperActivity

Utilities (unchanged):
- BookManager, BookSettings, BookmarkStore, BootNtpSync
- Dictionary, LookupHistory, TimeSync, OpdsServerStore

Libraries: PlaceholderCover, TableData, ChapterXPathIndexer
Scripts: inject_mod_version, generate_book_icon, preview_placeholder_cover
Docs: KOReader sync XPath mapping

Migration changes:
- ActivityWithSubactivity -> Activity base class
- Callback constructors -> finish()/setResult() pattern
- enterNewActivity() -> startActivityForResult()
- Activity::RenderLock&& -> RenderLock&&

These files won't compile yet - they reference mod settings and I18n
strings that will be added in subsequent phases.

Made-with: Cursor
2026-03-07 15:10:00 -05:00

2.1 KiB

Merge upstream/master into mod/master

Date: 2026-02-13
Branch: mod/merge-upstream (from mod/master)
Commit: 82bfbd8

Task

Merged 3 new upstream/master commits into the mod fork:

  1. 7a385d7 feat: Allow screenshot retrieval from device (#820)
  2. cb24947 feat: Add central logging pragma (#843) — replaces Serial.printf with LOG_* macros across ~50 files, adds Logging library
  3. 6e51afb fix: Account for nbsp character as non-breaking space (#757)

Conflicts Resolved

src/main.cpp (1 conflict region)

  • Kept mod's HalPowerManager (deep sleep, power saving) + upstream's Logging.h and LOG_* macros + screenshot serial handler (logSerial)

src/activities/boot_sleep/SleepActivity.cpp (3 conflict regions)

  • Kept mod's entire letterbox fill rework (~330 lines of dithering, edge caching, etc.)
  • Replaced upstream's reverted positioning logic (size-gated) with mod's always-compute-scale approach
  • Applied upstream's LOG_* pattern to all mod Serial.printf calls

Additional Changes (beyond conflict resolution)

  • lib/GfxRenderer/GfxRenderer.cpp — Fixed one Serial.printf that auto-merge missed converting to LOG_ERR (caused linker error with the new Logging library's #define Serial macro)
  • lib/hal/HalPowerManager.cpp — Converted 4 Serial.printf calls to LOG_DBG/LOG_ERR, added #include <Logging.h>
  • src/util/BookSettings.cpp — Converted 3 Serial.printf calls to LOG_DBG/LOG_ERR, replaced #include <HardwareSerial.h> with #include <Logging.h>
  • src/util/BookmarkStore.cpp — Converted 2 Serial.printf calls to LOG_ERR/LOG_DBG, added #include <Logging.h>
  • platformio.ini — Added -DENABLE_SERIAL_LOG and -DLOG_LEVEL=2 to [env:mod] build flags (was missing, other envs all have these)

Build Verification

PlatformIO build (pio run -e mod) succeeded:

  • RAM: 31.0% (101724/327680 bytes)
  • Flash: 96.8% (6342796/6553600 bytes)

Follow-up

  • The merge is on branch mod/merge-upstream — fast-forward mod/master when ready
  • The TxtReaderActivity.cpp has a pre-existing [[nodiscard]] warning for generateCoverBmp() (not introduced by this merge)