LibreTube/app/src/main/java/com/github/libretube/extensions/SeekBy.kt

11 lines
228 B
Kotlin

package com.github.libretube.extensions
import androidx.media3.common.Player
/**
* Forward or rewind by the provided [timeDiff] in milliseconds
*/
fun Player.seekBy(timeDiff: Long) {
seekTo(currentPosition + timeDiff)
}