Skip to content

feat(ux): page turning on button pressed if long-press chapter skip is disabled#451

Merged
daveallie merged 6 commits intocrosspoint-reader:masterfrom
osteotek:pageturn-btn-pressed
Jan 27, 2026
Merged

feat(ux): page turning on button pressed if long-press chapter skip is disabled#451
daveallie merged 6 commits intocrosspoint-reader:masterfrom
osteotek:pageturn-btn-pressed

Conversation

@osteotek
Copy link
Member

@osteotek osteotek commented Jan 20, 2026

Summary

  • If long-press chapter skip is disabled, turn pages on button pressed, not released
  • Makes page turning snappier
  • Refactors MappedInputManager for readability

AI Usage

Did you use AI tools to help write this code? < PARTIALLY>

Copilot AI review requested due to automatic review settings January 20, 2026 14:48
@osteotek osteotek changed the title feat(ux): page turning on button press if long-press chapter skip disabled feat(ux): page turning on button pressed if long-press chapter skip disabled Jan 20, 2026
@osteotek osteotek changed the title feat(ux): page turning on button pressed if long-press chapter skip disabled feat(ux): page turning on button pressed if long-press chapter skip is disabled Jan 20, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR improves the page-turning UX by making button presses more responsive when long-press chapter skip is disabled. Instead of waiting for button release, pages turn immediately on button press, providing a snappier feel.

Changes:

  • Modified button input handling logic to use wasPressed() instead of wasReleased() when long-press chapter skip is disabled
  • Renamed variables from prevReleased/nextReleased to prevTriggered/nextTriggered to reflect the conditional behavior
  • Applied changes consistently across all three reader activity types (XTC, TXT, and EPUB)

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
src/activities/reader/XtcReaderActivity.cpp Added conditional logic to trigger page turns on press vs release based on long-press setting, with skip page support
src/activities/reader/TxtReaderActivity.cpp Added conditional logic to trigger page turns on press vs release based on long-press setting
src/activities/reader/EpubReaderActivity.cpp Added conditional logic to trigger page turns on press vs release based on long-press setting, with chapter skip support

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@lukestein
Copy link
Contributor

lukestein commented Jan 25, 2026

Testing on device and seems to be working perfectly. Definitely makes page turns feel more snappy… to the point that I'll probably leave the long-press-for-chapter-turn setting turned off now!

Seems to work great with all of

  • epub and text
  • Long-press Chapter Skip: on, off (no effect as expected when ON)
  • Short Power Button Click: Page turn, ignore, sleep

@osteotek osteotek requested a review from daveallie January 25, 2026 19:15
daveallie
daveallie previously approved these changes Jan 27, 2026
@daveallie daveallie merged commit 49190cc into crosspoint-reader:master Jan 27, 2026
1 check passed
jdk2pq added a commit to jdk2pq/crosspoint-reader that referenced this pull request Jan 28, 2026
* master: (33 commits)
  feat: add HalDisplay and HalGPIO (crosspoint-reader#522)
  feat: Display epub metadata on Recents (crosspoint-reader#511)
  chore: Cut release 0.16.0
  fix: Correctly render italics on image alt placeholders (crosspoint-reader#569)
  chore: .gitignore: add compile_commands.json & .cache (crosspoint-reader#568)
  fix: Render keyboard entry over multiple lines (crosspoint-reader#567)
  fix: missing front layout in mapLabels() (crosspoint-reader#564)
  refactor: Re-work for OTA feature (crosspoint-reader#509)
  perf: optimize large EPUB indexing from O(n^2) to O(n) (crosspoint-reader#458)
  feat: Add Spanish hyphenation support (crosspoint-reader#558)
  feat: Add support to B&W filters to image covers (crosspoint-reader#476)
  feat(ux): page turning on button pressed if long-press chapter skip is disabled (crosspoint-reader#451)
  feat: Add status bar option "Full w/ Progress Bar" (crosspoint-reader#438)
  fix: Validate settings on read. (crosspoint-reader#492)
  fix: rotate origin in drawImage (crosspoint-reader#557)
  feat: Extract author from XTC/XTCH files (crosspoint-reader#563)
  fix: add txt books to recent tab (crosspoint-reader#526)
  docs: add font generation commands to builtin font headers (crosspoint-reader#547)
  docs: Update README with supported languages for EPUB  (crosspoint-reader#530)
  fix: Fix KOReader document md5 calculation for binary matching progress sync (crosspoint-reader#529)
  ...
Jessica765 pushed a commit to Jessica765/crosspoint-reader that referenced this pull request Feb 3, 2026
…s disabled (crosspoint-reader#451)

## Summary

* If long-press chapter skip is disabled, turn pages on button pressed,
not released
* Makes page turning snappier
* Refactors MappedInputManager for readability

---

### AI Usage

Did you use AI tools to help write this code? _**< PARTIALLY>**_

---------

Co-authored-by: Dave Allie <[email protected]>
Unintendedsideeffects pushed a commit to Unintendedsideeffects/crosspoint-reader that referenced this pull request Feb 17, 2026
…s disabled (crosspoint-reader#451)

## Summary

* If long-press chapter skip is disabled, turn pages on button pressed,
not released
* Makes page turning snappier
* Refactors MappedInputManager for readability

---

### AI Usage

Did you use AI tools to help write this code? _**< PARTIALLY>**_

---------

Co-authored-by: Dave Allie <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants