Change Android VideoView Orientation
I have a video VideoView
in an android app. When I do this in portrait orientation, the video fills the screen. But when I change orientation to landscape, the video takes up only half of the screen. I use FILL_PARENT
, FILL_PARENT
as the configuration parameters.
Is there a way the video can fill the screen in both orientations?
a source to share
You may want to consider creating two different layouts for portrait and landscape views. Let's assume you have a /res/layout/main.xml file. In the "/ res /" folder, create a child folder and name it "layout-land", the R file will be automatically generated! Here's a snapshot to keep it simple ...
alt text http://img826.imageshack.us/img826/5749/previewu.png
after you can edit each layout independently ... This is the most common way to deal with orientation changes when it comes to layouts.
Yours faithfully,
Igor
a source to share