Skip to content

Add automatic intro/outro skipping - #431

Merged
rRemix merged 3 commits into
rRemix:composefrom
996949805:skip-intro-outro
Nov 25, 2026
Merged

rRemix merged 3 commits into
rRemix:composefrom
996949805:skip-intro-outro

Conversation

@996949805

Copy link
Copy Markdown
Contributor

Summary

Adds an optional global setting to skip a configurable amount of time at the beginning and end of each track. Closes #430.

Useful for live recordings, audiobooks, podcasts and DJ mixes where the first and last seconds are often silence, applause or spoken intros.

Behavior

  • Settings → Play → Skip intro and outro toggle, with two 0–120 s sliders
  • On track start, seek to the intro position; a saved resume position that is already past the intro is preserved
  • At duration − outro, the track advances using the current repeat/shuffle mode
    • Repeat-one restarts the current track and re-applies the intro
    • Shuffle uses the real shuffle order
    • No next item behaves like a natural end of playback
  • Tracks shorter than intro + outro are left untouched, so nothing is skipped entirely

Implementation

  • Preference keys and normalized durations added to SettingPrefs; the settings state is exposed through PlaySettings
  • A small SkipIntroOutroLogic settings item follows the existing *Logic.kt + SwitchPreference pattern
  • MusicService polls the outro cutoff every 200 ms while playback is active and the option is enabled (independent of screen state)
  • Playback gains nextIndexRespectingMode and seekToIndex; next-item resolution uses Player.nextMediaItemIndex so shuffle order and repeat modes match natural playback
  • Strings added for English, zh-CN, zh-HK and zh-TW; other locales fall back to English

Verification

  • ./gradlew :app:assembleFossRelease succeeds (JDK 17, AGP 9.2.1)
  • Release APK built and signature-verified locally
  • Not yet verified on a physical device, so a runtime check would be appreciated before merging

🤖 Generated with Claude Code

996949805 and others added 3 commits November 19, 2026 16:18
Introduce a global toggle with configurable intro and outro durations
(0-120 seconds). Add the preference entries, view model state and a
settings item under Play.

Co-Authored-By: Claude Code <noreply@anthropic.com>
Seek to the configured intro position when a track starts, keeping an
existing resume position if it is already past the intro. While playing,
detect the outro cutoff and advance according to the current repeat and
shuffle mode, restarting the track in repeat-one mode. Songs shorter
than intro plus outro are left untouched.

Co-Authored-By: Claude Code <noreply@anthropic.com>
@rRemix
rRemix merged commit edbd8b7 into rRemix:compose Nov 25, 2026
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.

Add automatic intro/outro skipping for playback

2 participants