문제

I am adding MediaController to a VideoView, but it does not show up unless I tap the phone. The controller disappears after a while.

Is there a way I can have the MediaController show always?

Thanks Chris

도움이 되었습니까?

해결책

As Default mediacontroller will hide in 3 seconds of user's inactivity. you can set the timeout seconds by

new media controller().show(50000);

check this link

다른 팁

The below code shows MediaController always:

VideoView videoView;   
MediaController mc;  

videoView.setMediaController(new MediaController(this)  
    {
        public void hide()
        {
            System.out.println("HIDEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEHELLLOO");
            mc.show();
        }
    });
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top