From 8a750b4f15c632efd864c352e7facd3e99005221 Mon Sep 17 00:00:00 2001 From: saiteja Date: Thu, 10 Jan 2019 11:39:57 -0500 Subject: [PATCH] callback for seek --- .idea/caches/build_file_checksums.ser | Bin 0 -> 599 bytes .idea/codeStyles/Project.xml | 29 +++++++++++++ .idea/misc.xml | 38 ++++++++++++++++++ .idea/modules.xml | 10 +++++ .idea/runConfigurations.xml | 12 ++++++ .../halilibo/bvpkotlin/BetterVideoPlayer.kt | 1 + .../bvpkotlin/VideoProgressCallback.kt | 2 + 7 files changed, 92 insertions(+) create mode 100644 .idea/caches/build_file_checksums.ser create mode 100644 .idea/codeStyles/Project.xml create mode 100644 .idea/misc.xml create mode 100644 .idea/modules.xml create mode 100644 .idea/runConfigurations.xml diff --git a/.idea/caches/build_file_checksums.ser b/.idea/caches/build_file_checksums.ser new file mode 100644 index 0000000000000000000000000000000000000000..58cc83634772a22eb6ab4723169f8042cee03fce GIT binary patch literal 599 zcmZ4UmVvdnh`~NNKUXg?FQq6yGexf?KR>5fFEb@IQ7^qHF(oHeub?PDD>b=9F91S2 zm1gFoxMk*~I%lLNXBU^|7Q2L-Ts|(GuF1r}l-a(W(##Th_( zR`y#54~r#SWM*J;W8likPfT%3OfJbU@?_vF$tX%K&dAS6sVJ~_U;qK0at2z_zyOYkOxc*3?Qo+1hnodM1`+ic;2Yuy^n6xvl5^a zi&INVGV{`lVHyh=>KNESY8wU5+|zH>nY!n63Rkh5h)D^9v9nc7XmM&$aZGVyW=U#R zqC!DYVsT3sQ?pGE<97;pSbD?YY^{u!-em1Lur4Kb-1H7TtSwVJw zNls=SYKXwi{}|lZIq65T@uQhLL`z)WYnLzx;&HZicr-(q-YVs$dA0uLA3}as002*G B(0u>^ literal 0 HcmV?d00001 diff --git a/.idea/codeStyles/Project.xml b/.idea/codeStyles/Project.xml new file mode 100644 index 0000000..30aa626 --- /dev/null +++ b/.idea/codeStyles/Project.xml @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml new file mode 100644 index 0000000..b0c7b20 --- /dev/null +++ b/.idea/misc.xml @@ -0,0 +1,38 @@ + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 0000000..9d5caa0 --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,10 @@ + + + + + + + + + + \ No newline at end of file diff --git a/.idea/runConfigurations.xml b/.idea/runConfigurations.xml new file mode 100644 index 0000000..7f68460 --- /dev/null +++ b/.idea/runConfigurations.xml @@ -0,0 +1,12 @@ + + + + + + \ No newline at end of file diff --git a/bvpkotlin/src/main/java/com/halilibo/bvpkotlin/BetterVideoPlayer.kt b/bvpkotlin/src/main/java/com/halilibo/bvpkotlin/BetterVideoPlayer.kt index ca9dc08..4497a33 100644 --- a/bvpkotlin/src/main/java/com/halilibo/bvpkotlin/BetterVideoPlayer.kt +++ b/bvpkotlin/src/main/java/com/halilibo/bvpkotlin/BetterVideoPlayer.kt @@ -985,6 +985,7 @@ class BetterVideoPlayer @JvmOverloads constructor( override fun onProgressChanged(seekBar: SeekBar, progress: Int, fromUser: Boolean) { if (fromUser) { seekTo(progress) + mProgressCallback?.onUserSeek(progress) mPositionTextView.text = Util.getDurationString(progress.toLong(), false) } } diff --git a/bvpkotlin/src/main/java/com/halilibo/bvpkotlin/VideoProgressCallback.kt b/bvpkotlin/src/main/java/com/halilibo/bvpkotlin/VideoProgressCallback.kt index f5f1eed..ac6895f 100644 --- a/bvpkotlin/src/main/java/com/halilibo/bvpkotlin/VideoProgressCallback.kt +++ b/bvpkotlin/src/main/java/com/halilibo/bvpkotlin/VideoProgressCallback.kt @@ -3,4 +3,6 @@ package com.halilibo.bvpkotlin interface VideoProgressCallback { fun onProgressUpdate(position: Int, duration: Int) + fun onUserSeek(position: Int) + } \ No newline at end of file