init project
This commit is contained in:
191
EasyPlayerPro/src/main/res/layout/activity_about.xml
Normal file
191
EasyPlayerPro/src/main/res/layout/activity_about.xml
Normal file
@@ -0,0 +1,191 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<layout
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:background="@color/colorWhite">
|
||||
|
||||
<android.support.v7.widget.Toolbar
|
||||
android:id="@+id/toolbar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="66dp"
|
||||
android:background="@drawable/new_top_bg">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="版本信息"
|
||||
android:gravity="center"
|
||||
android:textColor="#ffffff"
|
||||
android:textSize="18sp"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_marginBottom="12dp"/>
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/toolbar_back"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="wrap_content"
|
||||
android:src="@drawable/new_nav_back"
|
||||
style="@style/Base.Widget.AppCompat.ActionButton"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_marginBottom="0dp"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
</android.support.v7.widget.Toolbar>
|
||||
|
||||
<ScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<android.support.constraint.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/version"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="15dp"
|
||||
android:text="EasyRTMP播放组件:"
|
||||
android:textSize="16sp"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/desc"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/about_info"
|
||||
android:textSize="15sp"
|
||||
android:lineSpacingExtra="5dp"
|
||||
android:layout_marginTop="8dp"
|
||||
app:layout_constraintTop_toBottomOf="@+id/version"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginRight="16dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/darwin_tv"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:layout_marginTop="20dp"
|
||||
android:layout_marginRight="16dp"
|
||||
android:text="EasyDarwin开源流媒体服务器:"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/desc" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/darwin_content_tv"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="26dp"
|
||||
android:layout_marginTop="5dp"
|
||||
android:layout_marginRight="16dp"
|
||||
android:text="http://www.easydarwin.org"
|
||||
android:textSize="14sp"
|
||||
android:textColor="@color/colorTheme2"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/darwin_tv" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/dss_tv"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:layout_marginTop="20dp"
|
||||
android:layout_marginRight="16dp"
|
||||
android:text="EasyDSS商用流媒体解决方案:"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/darwin_content_tv" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/dss_content_tv"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="26dp"
|
||||
android:layout_marginTop="5dp"
|
||||
android:layout_marginRight="16dp"
|
||||
android:text="http://www.easydss.com"
|
||||
android:textSize="14sp"
|
||||
android:textColor="@color/colorTheme2"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/dss_tv" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/nvr_tv"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:layout_marginTop="20dp"
|
||||
android:layout_marginRight="16dp"
|
||||
android:text="EasyNVR无插件直播方案:"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/dss_content_tv" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/nvr_content_tv"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="26dp"
|
||||
android:layout_marginTop="5dp"
|
||||
android:layout_marginRight="16dp"
|
||||
android:text="http://www.easynvr.com"
|
||||
android:textColor="@color/colorTheme2"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/nvr_tv" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/imageView"
|
||||
android:layout_width="150dp"
|
||||
android:layout_height="150dp"
|
||||
android:layout_marginTop="30dp"
|
||||
android:src="@drawable/new_android_pro"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/nvr_content_tv" />
|
||||
|
||||
<TextView
|
||||
android:text="Copyright @ Open.TSINGSEE.com"
|
||||
android:layout_height="40dp"
|
||||
android:layout_width="0dp"
|
||||
android:gravity="center"
|
||||
android:id="@+id/textView3"
|
||||
android:background="@color/colorTheme2"
|
||||
android:textColor="#FFFFFF"
|
||||
android:layout_marginTop="30dp"
|
||||
app:layout_constraintTop_toBottomOf="@+id/imageView"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent" />
|
||||
</android.support.constraint.ConstraintLayout>
|
||||
</ScrollView>
|
||||
</LinearLayout>
|
||||
|
||||
</layout>
|
||||
96
EasyPlayerPro/src/main/res/layout/activity_main_pro.xml
Normal file
96
EasyPlayerPro/src/main/res/layout/activity_main_pro.xml
Normal file
@@ -0,0 +1,96 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
tools:context="org.easydarwin.easyplayer.PlayActivity">
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:id="@+id/render_container"
|
||||
android:layout_gravity="center"
|
||||
android:background="#000000">
|
||||
|
||||
<org.easydarwin.easyplayer.views.ProVideoView
|
||||
android:id="@+id/video_view2"
|
||||
android:layout_width="match_parent"
|
||||
android:keepScreenOn="true"
|
||||
android:visibility="gone"
|
||||
android:layout_height="match_parent" />
|
||||
|
||||
<org.easydarwin.easyplayer.views.ProVideoView
|
||||
android:id="@+id/video_view"
|
||||
android:layout_width="match_parent"
|
||||
android:keepScreenOn="true"
|
||||
android:layout_height="match_parent" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/surface_cover"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="#000000"
|
||||
android:scaleType="centerCrop" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@android:id/progress"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="200dp"
|
||||
android:layout_gravity="center"
|
||||
android:gravity="center"
|
||||
android:background="@color/white"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ProgressBar
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="100dp"
|
||||
android:indeterminateBehavior="repeat"
|
||||
android:indeterminateDrawable="@drawable/anim" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:text="加载中"
|
||||
android:id="@+id/loading_speed"
|
||||
android:textColor="@color/colorTheme"
|
||||
android:gravity="center_horizontal"
|
||||
android:layout_height="wrap_content" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/live_video_snap_thumb"
|
||||
android:layout_width="50dp"
|
||||
android:layout_height="50dp"
|
||||
android:layout_gravity="right|top"
|
||||
android:layout_margin="3dp"
|
||||
android:clickable="true"
|
||||
android:gravity="center"
|
||||
android:onClick="onTakePictureThumbClicked"
|
||||
android:padding="3dp"
|
||||
android:scaleType="centerCrop"
|
||||
android:visibility="invisible" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/player_container"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="200dp"
|
||||
android:background="#fff"
|
||||
android:layout_gravity="center"
|
||||
android:gravity="center"
|
||||
android:visibility="gone"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/new_lost"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
</LinearLayout>
|
||||
</layout>
|
||||
63
EasyPlayerPro/src/main/res/layout/activity_media_files.xml
Executable file
63
EasyPlayerPro/src/main/res/layout/activity_media_files.xml
Executable file
@@ -0,0 +1,63 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
tools:context="org.easydarwin.easyplayer.activity.MediaFilesActivity">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:background="@color/colorWhite">
|
||||
|
||||
<android.support.v7.widget.Toolbar
|
||||
android:id="@+id/toolbar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="66dp"
|
||||
android:background="@drawable/new_top_bg">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="文件夹"
|
||||
android:gravity="center"
|
||||
android:textColor="#ffffff"
|
||||
android:textSize="18sp"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_marginBottom="12dp"/>
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/toolbar_back"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="wrap_content"
|
||||
android:src="@drawable/new_nav_back"
|
||||
style="@style/Base.Widget.AppCompat.ActionButton"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_marginBottom="0dp"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
</android.support.v7.widget.Toolbar>
|
||||
|
||||
<android.support.v4.view.ViewPager
|
||||
android:id="@+id/view_pager"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<android.support.v4.view.PagerTitleStrip
|
||||
android:id="@+id/pager_title_strip"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingTop="10dp"
|
||||
android:paddingBottom="10dp"
|
||||
android:background="#f2f2f2"
|
||||
android:textAlignment="center"
|
||||
android:textSize="16sp" />
|
||||
</android.support.v4.view.ViewPager>
|
||||
</LinearLayout>
|
||||
</layout>
|
||||
120
EasyPlayerPro/src/main/res/layout/activity_play_list.xml
Normal file
120
EasyPlayerPro/src/main/res/layout/activity_play_list.xml
Normal file
@@ -0,0 +1,120 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout>
|
||||
|
||||
<RelativeLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:background="#ffffff"
|
||||
tools:context="org.easydarwin.easyplayer.activity.PlayListActivity">
|
||||
|
||||
<android.support.v7.widget.Toolbar
|
||||
android:id="@+id/toolbar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="66dp"
|
||||
android:background="@drawable/new_top_bg">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="EasyPlayer Pro"
|
||||
android:gravity="center"
|
||||
android:textColor="#ffffff"
|
||||
android:textSize="18sp"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_marginBottom="12dp"/>
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/toolbar_about"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="wrap_content"
|
||||
android:src="@drawable/new_version1"
|
||||
style="@style/Base.Widget.AppCompat.ActionButton"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_marginBottom="0dp"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
</android.support.v7.widget.Toolbar>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/bottom_ll"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="54dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:background="#f2f2f2"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/toolbar_add"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_width="0dp"
|
||||
android:layout_weight="1"
|
||||
android:text="地址"
|
||||
android:textColor="@drawable/new_color_text"
|
||||
android:textSize="13sp"
|
||||
android:drawableTop="@drawable/new_address_btn"
|
||||
android:paddingTop="8dp"
|
||||
style="@style/Base.Widget.AppCompat.ActionButton"
|
||||
android:layout_gravity="end" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/toolbar_file"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_width="0dp"
|
||||
android:layout_weight="1"
|
||||
android:text="文件夹"
|
||||
android:textColor="@drawable/new_color_text"
|
||||
android:textSize="13sp"
|
||||
android:drawableTop="@drawable/new_file_btn"
|
||||
android:paddingTop="8dp"
|
||||
android:onClick="fileList"
|
||||
style="@style/Base.Widget.AppCompat.ActionButton"
|
||||
android:layout_gravity="end" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/toolbar_setting"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_width="0dp"
|
||||
android:layout_weight="1"
|
||||
android:text="设置"
|
||||
android:textColor="@drawable/new_color_text"
|
||||
android:textSize="13sp"
|
||||
android:drawableTop="@drawable/new_setting_btn"
|
||||
android:paddingTop="8dp"
|
||||
style="@style/Base.Widget.AppCompat.ActionButton"
|
||||
android:layout_gravity="end" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<android.support.v4.widget.SwipeRefreshLayout
|
||||
android:id="@+id/pull_to_refresh"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_below="@id/toolbar"
|
||||
android:layout_above="@id/bottom_ll">
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<android.support.v7.widget.RecyclerView
|
||||
android:id="@+id/recycler"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" />
|
||||
</FrameLayout>
|
||||
|
||||
</android.support.v4.widget.SwipeRefreshLayout>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
</layout>
|
||||
31
EasyPlayerPro/src/main/res/layout/activity_scan_qr.xml
Normal file
31
EasyPlayerPro/src/main/res/layout/activity_scan_qr.xml
Normal file
@@ -0,0 +1,31 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<FrameLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<com.budiyev.android.codescanner.CodeScannerView
|
||||
android:id="@+id/scanner_view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
app:autoFocusButtonColor="@android:color/white"
|
||||
app:autoFocusButtonVisible="false"
|
||||
app:flashButtonColor="@android:color/white"
|
||||
app:flashButtonVisible="true"
|
||||
app:frameColor="@android:color/white"
|
||||
app:frameCornersSize="50dp"
|
||||
app:frameAspectRatioWidth="1"
|
||||
app:frameAspectRatioHeight="1"
|
||||
app:frameSize="0.75"
|
||||
app:frameThickness="2dp"
|
||||
app:maskColor="#66000000"/>
|
||||
|
||||
<ImageView
|
||||
android:layout_width="56dp"
|
||||
android:src="@drawable/new_nav_back"
|
||||
android:padding="18dp"
|
||||
android:onClick="onClose"
|
||||
android:layout_height="56dp" />
|
||||
|
||||
</FrameLayout>
|
||||
108
EasyPlayerPro/src/main/res/layout/activity_setting.xml
Normal file
108
EasyPlayerPro/src/main/res/layout/activity_setting.xml
Normal file
@@ -0,0 +1,108 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/colorWhite"
|
||||
android:orientation="vertical">
|
||||
|
||||
<android.support.v7.widget.Toolbar
|
||||
android:id="@+id/toolbar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="66dp"
|
||||
android:background="@drawable/new_top_bg">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="设置"
|
||||
android:gravity="center"
|
||||
android:textColor="#ffffff"
|
||||
android:textSize="18sp"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_marginBottom="12dp"/>
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/toolbar_back"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="wrap_content"
|
||||
android:src="@drawable/new_nav_back"
|
||||
style="@style/Base.Widget.AppCompat.ActionButton"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_marginBottom="0dp"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
</android.support.v7.widget.Toolbar>
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="56dp"
|
||||
android:gravity="center_vertical"
|
||||
android:padding="12dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="UDP模式观看视频(默认使用TCP模式)"
|
||||
android:textSize="15sp"
|
||||
android:textColor="#4c4c4c"/>
|
||||
|
||||
<Switch
|
||||
android:id="@+id/udp_switch"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:thumb="@drawable/switch_custom_thumb_selector"
|
||||
android:track="@drawable/switch_custom_track_selector"
|
||||
android:layout_alignParentRight="true"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:background="#f0f0f0"
|
||||
android:layout_marginLeft="12dp"
|
||||
android:layout_marginRight="12dp" />
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="56dp"
|
||||
android:gravity="center_vertical"
|
||||
android:padding="12dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="使用MediaCodec解码"
|
||||
android:textSize="15sp"
|
||||
android:textColor="#4c4c4c"/>
|
||||
|
||||
<Switch
|
||||
android:id="@+id/codec_switch"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:thumb="@drawable/switch_custom_thumb_selector"
|
||||
android:track="@drawable/switch_custom_track_selector"
|
||||
android:layout_alignParentRight="true"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:background="#f0f0f0"
|
||||
android:layout_marginLeft="12dp"
|
||||
android:layout_marginRight="12dp" />
|
||||
|
||||
</LinearLayout>
|
||||
</layout>
|
||||
50
EasyPlayerPro/src/main/res/layout/activity_splash.xml
Normal file
50
EasyPlayerPro/src/main/res/layout/activity_splash.xml
Normal file
@@ -0,0 +1,50 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@drawable/new_splash_bg">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="120dp"
|
||||
android:layout_height="120dp"
|
||||
android:layout_centerInParent="true"
|
||||
android:contentDescription="@null"
|
||||
android:src="@drawable/new_splash_image" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_marginTop="40dp"
|
||||
android:gravity="center"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="20sp"
|
||||
android:text="EasyPlayer Pro" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/txt_copyright"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:gravity="center"
|
||||
android:textColor="#666"
|
||||
android:textSize="12sp"
|
||||
android:text="Copyright @ Open.TSINGSEE.com" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/txt_version"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_above="@+id/txt_copyright"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:textColor="#666"
|
||||
android:textSize="12sp"
|
||||
android:text="EasyPlayer 1.0.0" />
|
||||
|
||||
|
||||
|
||||
</RelativeLayout>
|
||||
9
EasyPlayerPro/src/main/res/layout/fragment_media_file.xml
Executable file
9
EasyPlayerPro/src/main/res/layout/fragment_media_file.xml
Executable file
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<android.support.v7.widget.RecyclerView
|
||||
android:id="@+id/recycler"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" />
|
||||
|
||||
</layout>
|
||||
32
EasyPlayerPro/src/main/res/layout/image_picker_item.xml
Executable file
32
EasyPlayerPro/src/main/res/layout/image_picker_item.xml
Executable file
@@ -0,0 +1,32 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<org.easydarwin.easyplayer.views.SquareImageView
|
||||
android:id="@+id/image_icon"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="128dp"
|
||||
android:layout_margin="1dp"
|
||||
android:background="#666"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="centerCrop" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/image_play"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:src="@drawable/new_player"/>
|
||||
|
||||
<CheckBox
|
||||
android:id="@+id/image_checkbox"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="right|top"
|
||||
android:visibility="gone" />
|
||||
|
||||
</FrameLayout>
|
||||
</layout>
|
||||
182
EasyPlayerPro/src/main/res/layout/media_controller.xml
Normal file
182
EasyPlayerPro/src/main/res/layout/media_controller.xml
Normal file
@@ -0,0 +1,182 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:id="@+id/media_controller_ll"
|
||||
android:background="#6000"
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="30dp"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_speed"
|
||||
style="@style/Widget.AppCompat.ActionButton"
|
||||
android:layout_width="0dp"
|
||||
android:layout_weight="1"
|
||||
android:layout_height="wrap_content"
|
||||
android:visibility="gone"
|
||||
android:textColor="@color/white" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_fps"
|
||||
style="@style/Widget.AppCompat.ActionButton"
|
||||
android:layout_width="0dp"
|
||||
android:layout_weight="1"
|
||||
android:visibility="gone"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="@color/white" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_kbps"
|
||||
style="@style/Widget.AppCompat.ActionButton"
|
||||
android:layout_width="0dp"
|
||||
android:layout_weight="1"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="@color/white"
|
||||
android:visibility="gone" />
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="30dp"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/slow"
|
||||
android:layout_weight="1"
|
||||
style="@android:style/MediaButton.Next"
|
||||
android:src="@drawable/new_slow_btn"
|
||||
android:contentDescription="@string/description" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/rewind"
|
||||
android:layout_weight="1"
|
||||
style="@android:style/MediaButton.Rew"
|
||||
android:src="@drawable/new_moveback_btn"
|
||||
android:contentDescription="@string/description" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/pause"
|
||||
android:layout_weight="1"
|
||||
style="@android:style/MediaButton.Play"
|
||||
android:src="@drawable/new_stop_white"
|
||||
android:contentDescription="@string/description" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/fast_forward"
|
||||
android:layout_weight="1"
|
||||
style="@android:style/MediaButton.Ffwd"
|
||||
android:src="@drawable/new_forward_btn"
|
||||
android:contentDescription="@string/description" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/fast"
|
||||
android:layout_weight="1"
|
||||
style="@android:style/MediaButton.Ffwd"
|
||||
android:src="@drawable/new_fast_btn"
|
||||
android:contentDescription="@string/description" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="30dp"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal"
|
||||
android:paddingTop="4dip">
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/action_take_picture"
|
||||
style="@style/Widget.AppCompat.ActionButton"
|
||||
android:layout_width="0dp"
|
||||
android:layout_weight="1"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/new_snapshot_btn" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/action_record"
|
||||
style="@style/Widget.AppCompat.ActionButton"
|
||||
android:layout_width="0dp"
|
||||
android:layout_weight="1"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/new_videotape_btn" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_record_time"
|
||||
android:layout_width="0dp"
|
||||
android:layout_weight="1"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:visibility="gone"
|
||||
android:textColor="#ff0000"
|
||||
android:drawablePadding="5dp"
|
||||
android:drawableLeft="@drawable/red_dot"
|
||||
android:text="00:00" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/action_change_mode"
|
||||
style="@style/Widget.AppCompat.ActionButton"
|
||||
android:layout_width="0dp"
|
||||
android:layout_weight="1"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/new_stretch_btn" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/fullscreen"
|
||||
style="@style/Widget.AppCompat.ActionButton"
|
||||
android:layout_width="0dp"
|
||||
android:layout_weight="1"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/new_full" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="30dp"
|
||||
android:id="@+id/seek_bar_container"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/time_current"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:paddingLeft="4dip"
|
||||
android:paddingRight="4dip"
|
||||
android:paddingTop="4dip"
|
||||
android:textSize="14sp"
|
||||
android:textColor="@color/white"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<SeekBar
|
||||
android:id="@+id/media_controller_progress"
|
||||
style="@style/CustomSeekbarStyle"
|
||||
android:progress="10"
|
||||
android:secondaryProgress="60"
|
||||
android:layout_width="0dip"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/total_time"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:paddingLeft="4dip"
|
||||
android:textColor="@color/white"
|
||||
android:paddingRight="4dip"
|
||||
android:paddingTop="4dip"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
@@ -0,0 +1,35 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<android.support.constraint.ConstraintLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/colorWhite">
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/new_media_scan"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/new_scan_btn"
|
||||
android:background="@null"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
android:layout_marginRight="8dp"
|
||||
app:layout_constraintTop_toTopOf="@id/new_media_source_url"
|
||||
app:layout_constraintBottom_toBottomOf="@id/new_media_source_url" />
|
||||
|
||||
|
||||
<EditText
|
||||
android:id="@+id/new_media_source_url"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="60dp"
|
||||
android:layout_marginStart="8dp"
|
||||
android:layout_marginLeft="8dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:hint="输入RTSP/RTMP/HTTP/HLS地址"
|
||||
app:layout_constraintRight_toLeftOf="@id/new_media_scan"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</android.support.constraint.ConstraintLayout>
|
||||
59
EasyPlayerPro/src/main/res/layout/video_source_item.xml
Normal file
59
EasyPlayerPro/src/main/res/layout/video_source_item.xml
Normal file
@@ -0,0 +1,59 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout>
|
||||
|
||||
<android.support.v7.widget.CardView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="240dp"
|
||||
android:layout_marginLeft="@dimen/activity_horizontal_margin"
|
||||
android:layout_marginRight="@dimen/activity_horizontal_margin"
|
||||
android:layout_marginTop="@dimen/activity_vertical_margin">
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/video_source_item_thumb"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" />
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="bottom"
|
||||
android:background="@color/black_overlay"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/video_source_item_name"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center_vertical"
|
||||
android:maxHeight="40dp"
|
||||
android:minHeight="40dp"
|
||||
android:ellipsize="end"
|
||||
android:paddingLeft="8dp"
|
||||
android:paddingRight="8dp"
|
||||
android:text="9"
|
||||
android:textColor="#ffffff" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/video_source_item_audience_number"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:maxHeight="40dp"
|
||||
android:minHeight="40dp"
|
||||
android:paddingLeft="8dp"
|
||||
android:paddingRight="8dp"
|
||||
android:text="实时观看人数:10"
|
||||
android:textColor="#ffffff" />
|
||||
</LinearLayout>
|
||||
|
||||
</FrameLayout>
|
||||
</android.support.v7.widget.CardView>
|
||||
</layout>
|
||||
Reference in New Issue
Block a user