1 <FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
 2     xmlns:tools="http://schemas.android.com/tools"
 3     android:layout_width="match_parent"
 4     android:layout_height="match_parent"
 5     tools:context="com.example.videoview.MainActivity" >
 6 
 7     <VideoView
 8         android:id="@+id/videoView"
 9         android:layout_width="match_parent"
10         android:layout_height="416dp" />
11 
12     <LinearLayout
13         android:id="@+id/linearLayout"
14         android:layout_width="match_parent"
15         android:layout_height="wrap_content"
16         android:layout_gravity="bottom"
17         android:orientation="horizontal" >
18 
19         <Button
20             android:id="@+id/start"
21             android:layout_width="wrap_content"
22             android:layout_height="wrap_content"
23             android:text="开始" />
24 
25         <Button
26             android:id="@+id/pause"
27             android:layout_width="wrap_content"
28             android:layout_height="wrap_content"
29             android:text="暂停" />
30 
31         <Button
32             android:id="@+id/seekto"
33             android:layout_width="wrap_content"
34             android:layout_height="wrap_content"
35             android:text="3秒处" />
36     </LinearLayout>
37 
38 </FrameLayout>
activity_main.xml

相关文章: