Quantcast
Channel: MediaController positioning over VideoView - Stack Overflow
Browsing latest articles
Browse All 11 View Live

Answer by Vishnu Priyaa for MediaController positioning over VideoView

Put your video view inside a linear layout <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto"...

View Article



Answer by Sasha Shpota for MediaController positioning over VideoView

With java 8: videoView.setOnPreparedListener(mediaPlayer -> mediaPlayer.setOnVideoSizeChangedListener( (player, width, height) -> { MediaController controller = new...

View Article

Answer by Humberto2991 for MediaController positioning over VideoView

this is the first time I answer a question in stackoverflow, I only insert a VideoView inside a FrameLayout with same measures both. MediaController will be at the bottom of the FrameLayout. This...

View Article

Answer by Anh Duy for MediaController positioning over VideoView

//It work good with me <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent"...

View Article

Answer by bughi for MediaController positioning over VideoView

I found really easy solution. Just wrap the videoView in a FrameLayout then you can add the MediaController to that FrameLayout from code, like this: MediaController mc = new MediaController(context);...

View Article


Answer by Hafiz for MediaController positioning over VideoView

I encounter the same problem recently, using setAnchorView(videoView) will set the controller fully under VideoView instead hovering on the bottom area of it. My VideoView is one third screen in upper...

View Article

Answer by bk138 for MediaController positioning over VideoView

Setting the anchor view will only work if the videoview size is known - it will not be upon init. But you can do something like this: video.setOnPreparedListener(new OnPreparedListener() { @Override...

View Article

Answer by Rongan for MediaController positioning over VideoView

I use this code to solve it. mediaController.setPadding(0, 0, 0, px); to set the mediacontroller view to the position you want. Hope this help you.

View Article


Answer by CommonsWare for MediaController positioning over VideoView

Frankly, I'd just write my own controller. In fact, I did once. That being said, try setAnchorView() -- by my reading of the source code, the MediaController will appear at the bottom of whatever the...

View Article


MediaController positioning over VideoView

I have a VideoView that takes up the top half of the Activity in portrait orientation with the bottom half of the screen showing some images and text. I am playing a rtsp video stream in the video...

View Article

Answer by Stefan Zhelyazkov for MediaController positioning over VideoView

I did it by wrapping the VideoView inside a LinearView such that the LinearView has layout_width="match_parent" so that it always stretches to the extent of the screen but layout_height="wrap_content"...

View Article
Browsing latest articles
Browse All 11 View Live




Latest Images