79.7 Adding the MediaController to the Video View
As the VideoPlayer application currently stands, there is no way for the user to control playback. As previously outlined, this can be achieved using the MediaController class. To add a controller to the VideoView, modify the configureVideoView() method once again:
package com.ebookfrenzy.videoplayer
.
.
import android.widget.MediaController
import kotlinx.android.synthetic.main.activity_main.*
class MainActivity : AppCompatActivity() {
private var mediaController: MediaController? = null
.
.
private fun configureVideoView() {
videoView1.setVideoURI(Uri.parse("android.resource://"
+ getPackageName() + "/" + R.raw...