Skip to content

Add endFile calllback to EventObserver#16

Open
tymmesyde wants to merge 2 commits into
jarnedemeulemeester:mainfrom
Stremio:feat/end-file-event
Open

Add endFile calllback to EventObserver#16
tymmesyde wants to merge 2 commits into
jarnedemeulemeester:mainfrom
Stremio:feat/end-file-event

Conversation

@tymmesyde
Copy link
Copy Markdown

@tymmesyde tymmesyde commented Mar 10, 2026

Add mpv_event_end_file to the EventObserver with reason and error code
Let me know if you think this is fine to add and if it needs some changes

private fun eventObserver() = object : MPVLib.EventObserver {
   ...
   override fun endFile(reason: Int, error: Int) {
        when (reason) {
            MPV_END_FILE_REASON_ERROR -> Log.e("Player errored: ${error}")
            else -> Log.d("Player ended")
        }
    }
}

@tymmesyde tymmesyde changed the title feat: add end file event Add endFile calllback to EventObserver Mar 10, 2026
@tymmesyde tymmesyde force-pushed the feat/end-file-event branch 3 times, most recently from c1640e3 to 347463b Compare April 8, 2026 16:32
@tymmesyde tymmesyde force-pushed the feat/end-file-event branch from 347463b to e8dd4bf Compare April 8, 2026 16:40
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.

1 participant