Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
android_vedio
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
android
android_vedio
Commits
6949e49d
Commit
6949e49d
authored
Aug 16, 2023
by
jyx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
代码优化
parent
f40d8f5a
Changes
15
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
1237 additions
and
16 deletions
+1237
-16
build.gradle
video/app/build.gradle
+3
-1
AndroidManifest.xml
video/app/src/main/AndroidManifest.xml
+5
-0
NotificationController.kt
.../com/duben/happyplaylet/manager/NotificationController.kt
+65
-0
VipPresenter.kt
...ava/com/duben/happyplaylet/mvp/presenters/VipPresenter.kt
+31
-4
VipView.kt
...src/main/java/com/duben/happyplaylet/mvp/views/VipView.kt
+3
-0
NewVipActivity.kt
...ava/com/duben/happyplaylet/ui/activitys/NewVipActivity.kt
+668
-0
VipActivity.kt
...n/java/com/duben/happyplaylet/ui/activitys/VipActivity.kt
+5
-0
VipBannerAdapter.java
...a/com/duben/happyplaylet/ui/adapter/VipBannerAdapter.java
+36
-0
MainFragment.kt
...n/java/com/duben/happyplaylet/ui/fragment/MainFragment.kt
+3
-6
VipPayCancelDialog.kt
...a/com/duben/happyplaylet/ui/widgets/VipPayCancelDialog.kt
+51
-0
GlideUtils.kt
...o/app/src/main/java/com/duben/library/utils/GlideUtils.kt
+14
-5
push_left_out.xml
video/app/src/main/res/anim/push_left_out.xml
+16
-0
activity_new_vip.xml
video/app/src/main/res/layout/activity_new_vip.xml
+240
-0
dialog_vip_pay_cancel.xml
video/app/src/main/res/layout/dialog_vip_pay_cancel.xml
+92
-0
styles.xml
video/app/src/main/res/values/styles.xml
+5
-0
No files found.
video/app/build.gradle
View file @
6949e49d
...
@@ -193,10 +193,12 @@ dependencies {
...
@@ -193,10 +193,12 @@ dependencies {
implementation
'com.orhanobut:logger:2.2.0'
implementation
'com.orhanobut:logger:2.2.0'
// 权限
// 权限
implementation
'com.guolindev.permissionx:permissionx:1.6.4'
implementation
'com.guolindev.permissionx:permissionx:1.6.4'
// GSON
implementation
'com.google.code.gson:gson:2.8.5'
// 图片加载
// 图片加载
implementation
'com.github.bumptech.glide:glide:4.11.0'
implementation
'com.github.bumptech.glide:glide:4.11.0'
implementation
'com.google.code.gson:gson:2.8.5'
annotationProcessor
'com.github.bumptech.glide:compiler:4.11.0'
annotationProcessor
'com.github.bumptech.glide:compiler:4.11.0'
implementation
(
'jp.wasabeef:glide-transformations:4.3.0'
)
// 65536
// 65536
implementation
'androidx.multidex:multidex:2.0.1'
implementation
'androidx.multidex:multidex:2.0.1'
// 附件下载更新
// 附件下载更新
...
...
video/app/src/main/AndroidManifest.xml
View file @
6949e49d
...
@@ -193,6 +193,11 @@
...
@@ -193,6 +193,11 @@
android:hardwareAccelerated=
"true"
android:hardwareAccelerated=
"true"
android:screenOrientation=
"portrait"
/>
android:screenOrientation=
"portrait"
/>
<activity
android:name=
".ui.activitys.NewVipActivity"
android:exported=
"false"
android:theme=
"@style/TransparentTheme"
/>
<service
<service
android:name=
".ui.service.UpdateService"
android:name=
".ui.service.UpdateService"
android:exported=
"true"
/>
android:exported=
"true"
/>
...
...
video/app/src/main/java/com/duben/happyplaylet/manager/NotificationController.kt
0 → 100644
View file @
6949e49d
package
com.duben.happyplaylet.manager
import
android.app.Notification
import
android.app.NotificationChannel
import
android.app.NotificationManager
import
android.content.Context
import
android.graphics.Color
import
android.os.Build
import
androidx.core.app.NotificationCompat
import
com.duben.happyplaylet.MintsApplication
import
com.duben.happyplaylet.R
object
NotificationController
{
private
const
val
MY_NOTIFICATION_CHANNEL
=
"default"
private
const
val
MY_NOTIFICATION_ID
=
0
x1234
fun
buildNotification
()
{
val
ctx
=
MintsApplication
.
getContext
()
val
notificationManager
=
ctx
.
getSystemService
(
Context
.
NOTIFICATION_SERVICE
)
as
NotificationManager
if
(
Build
.
VERSION
.
SDK_INT
>=
Build
.
VERSION_CODES
.
O
)
{
val
builder
=
Notification
.
Builder
(
ctx
,
MY_NOTIFICATION_CHANNEL
)
builder
.
setContentTitle
(
"我是标题"
)
.
setContentText
(
"我是内容"
)
.
setSmallIcon
(
R
.
mipmap
.
ic_launcher_main
)
.
setWhen
(
System
.
currentTimeMillis
())
.
setTicker
(
"我是测试内容"
)
.
setOngoing
(
true
)
// 设置常驻
notificationManager
.
notify
(
MY_NOTIFICATION_ID
,
builder
.
build
());
val
channel
=
NotificationChannel
(
MY_NOTIFICATION_CHANNEL
,
MY_NOTIFICATION_CHANNEL
,
NotificationManager
.
IMPORTANCE_DEFAULT
)
// 闪光灯
channel
.
enableLights
(
true
)
// 震动
channel
.
enableVibration
(
true
)
// 是否在桌面icon右上角展示小红点
channel
.
lightColor
=
Color
.
GREEN
//
channel
.
setShowBadge
(
true
)
//是否在久按桌面图标时显示此渠道的通知
notificationManager
.
createNotificationChannel
(
channel
)
}
else
{
val
builder
=
NotificationCompat
.
Builder
(
ctx
)
//设置标题
builder
.
setContentTitle
(
"我是标题"
)
.
setContentText
(
"我是内容"
)
.
setSmallIcon
(
R
.
mipmap
.
ic_launcher_main
)
.
setWhen
(
System
.
currentTimeMillis
())
.
setTicker
(
"我是测试内容"
)
.
setDefaults
(
Notification
.
DEFAULT_SOUND
)
.
setOngoing
(
true
)
// 设置常驻
notificationManager
.
notify
(
10
,
builder
.
build
());
}
}
}
\ No newline at end of file
video/app/src/main/java/com/duben/happyplaylet/mvp/presenters/VipPresenter.kt
View file @
6949e49d
...
@@ -2,15 +2,12 @@ package com.duben.happyplaylet.mvp.presenters
...
@@ -2,15 +2,12 @@ package com.duben.happyplaylet.mvp.presenters
import
com.duben.happyplaylet.MintsApplication
import
com.duben.happyplaylet.MintsApplication
import
com.duben.happyplaylet.manager.AppHttpManager
import
com.duben.happyplaylet.manager.AppHttpManager
import
com.duben.happyplaylet.mvp.model.BaseResponse
import
com.duben.happyplaylet.mvp.model.VipBean
import
com.duben.happyplaylet.mvp.model.WxPayParamBean
import
com.duben.happyplaylet.mvp.views.VipView
import
com.duben.happyplaylet.mvp.views.VipView
import
com.duben.library.net.neterror.BaseSubscriber
import
com.duben.library.net.neterror.BaseSubscriber
import
com.duben.library.net.neterror.Throwable
import
com.duben.library.net.neterror.Throwable
import
com.duben.happyplaylet.common.DeviceInfo
import
com.duben.happyplaylet.common.DeviceInfo
import
com.duben.happyplaylet.manager.UserManager
import
com.duben.happyplaylet.manager.UserManager
import
com.duben.happyplaylet.mvp.model.
UserBean
import
com.duben.happyplaylet.mvp.model.
*
import
com.duben.happyplaylet.utils.DeviceUuidFactory
import
com.duben.happyplaylet.utils.DeviceUuidFactory
import
java.util.*
import
java.util.*
...
@@ -209,4 +206,34 @@ class VipPresenter : BasePresenter<VipView>() {
...
@@ -209,4 +206,34 @@ class VipPresenter : BasePresenter<VipView>() {
}
}
})
})
}
}
fun
orders
()
{
AppHttpManager
.
getInstance
(
loanApplication
)
.
call
(
loanService
.
orders
(),
object
:
BaseSubscriber
<
BaseResponse
<
BannerList
>>()
{
override
fun
onCompleted
()
{
if
(
isLinkView
)
return
}
override
fun
onError
(
e
:
Throwable
)
{
if
(
isLinkView
)
return
}
override
fun
onNext
(
baseResponse
:
BaseResponse
<
BannerList
>)
{
if
(
isLinkView
)
return
val
code
=
baseResponse
.
status
val
message
=
baseResponse
.
message
when
(
code
)
{
200
->
{
view
.
ordersSuc
(
baseResponse
.
data
)
}
else
->
{
view
.
showToast
(
message
)
}
}
}
})
}
}
}
\ No newline at end of file
video/app/src/main/java/com/duben/happyplaylet/mvp/views/VipView.kt
View file @
6949e49d
package
com.duben.happyplaylet.mvp.views
package
com.duben.happyplaylet.mvp.views
import
com.duben.happyplaylet.mvp.model.BannerList
import
com.duben.happyplaylet.mvp.model.VipBean
import
com.duben.happyplaylet.mvp.model.VipBean
import
com.duben.happyplaylet.mvp.model.WxPayParamBean
import
com.duben.happyplaylet.mvp.model.WxPayParamBean
...
@@ -7,4 +8,6 @@ interface VipView : BaseView {
...
@@ -7,4 +8,6 @@ interface VipView : BaseView {
fun
getVipProductSuc
(
data
:
VipBean
)
fun
getVipProductSuc
(
data
:
VipBean
)
fun
getVipPayParamsSuc
(
payChannel
:
String
,
data
:
WxPayParamBean
)
fun
getVipPayParamsSuc
(
payChannel
:
String
,
data
:
WxPayParamBean
)
fun
queryVipOrderSuc
(
isPay
:
Boolean
)
fun
queryVipOrderSuc
(
isPay
:
Boolean
)
fun
ordersSuc
(
data
:
BannerList
?)
}
}
\ No newline at end of file
video/app/src/main/java/com/duben/happyplaylet/ui/activitys/NewVipActivity.kt
0 → 100644
View file @
6949e49d
This diff is collapsed.
Click to expand it.
video/app/src/main/java/com/duben/happyplaylet/ui/activitys/VipActivity.kt
View file @
6949e49d
...
@@ -25,6 +25,7 @@ import com.duben.happyplaylet.R
...
@@ -25,6 +25,7 @@ import com.duben.happyplaylet.R
import
com.duben.happyplaylet.common.AppConfig
import
com.duben.happyplaylet.common.AppConfig
import
com.duben.happyplaylet.common.Constant
import
com.duben.happyplaylet.common.Constant
import
com.duben.happyplaylet.manager.UserManager
import
com.duben.happyplaylet.manager.UserManager
import
com.duben.happyplaylet.mvp.model.BannerList
import
com.duben.happyplaylet.mvp.model.VipBean
import
com.duben.happyplaylet.mvp.model.VipBean
import
com.duben.happyplaylet.mvp.model.WxPayParamBean
import
com.duben.happyplaylet.mvp.model.WxPayParamBean
import
com.duben.happyplaylet.mvp.presenters.VipPresenter
import
com.duben.happyplaylet.mvp.presenters.VipPresenter
...
@@ -219,6 +220,10 @@ class VipActivity : BaseActivity(), VipView, View.OnClickListener, VipAdapter.On
...
@@ -219,6 +220,10 @@ class VipActivity : BaseActivity(), VipView, View.OnClickListener, VipAdapter.On
}
}
}
}
override
fun
ordersSuc
(
data
:
BannerList
?)
{
}
override
fun
onKeyDown
(
keyCode
:
Int
,
event
:
KeyEvent
?):
Boolean
{
override
fun
onKeyDown
(
keyCode
:
Int
,
event
:
KeyEvent
?):
Boolean
{
when
(
keyCode
)
{
when
(
keyCode
)
{
KeyEvent
.
KEYCODE_BACK
->
{
KeyEvent
.
KEYCODE_BACK
->
{
...
...
video/app/src/main/java/com/duben/happyplaylet/ui/adapter/VipBannerAdapter.java
0 → 100644
View file @
6949e49d
package
com
.
duben
.
happyplaylet
.
ui
.
adapter
;
import
android.content.Context
;
import
android.view.LayoutInflater
;
import
android.view.ViewGroup
;
import
com.duben.happyplaylet.R
;
import
com.duben.happyplaylet.mvp.model.VedioBean
;
import
com.duben.library.utils.GlideUtils
;
import
com.youth.banner.adapter.BannerAdapter
;
import
java.util.List
;
public
class
VipBannerAdapter
extends
BannerAdapter
<
VedioBean
,
ImageTitleHolder
>
{
private
Context
context
;
public
VipBannerAdapter
(
List
<
VedioBean
>
data
)
{
super
(
data
);
}
@Override
public
ImageTitleHolder
onCreateHolder
(
ViewGroup
parent
,
int
viewType
)
{
context
=
parent
.
getContext
();
return
new
ImageTitleHolder
(
LayoutInflater
.
from
(
context
).
inflate
(
R
.
layout
.
banner_image_title
,
parent
,
false
));
}
@Override
public
void
onBindView
(
ImageTitleHolder
holder
,
VedioBean
data
,
int
position
,
int
size
)
{
if
(
data
.
getCoverImage
()
!=
null
)
{
GlideUtils
.
INSTANCE
.
loadImageViewGifForCenterCrop
(
context
,
data
.
getCoverImage
(),
holder
.
imageView
);
}
holder
.
title
.
setText
(
data
.
getTitle
());
}
}
video/app/src/main/java/com/duben/happyplaylet/ui/fragment/MainFragment.kt
View file @
6949e49d
...
@@ -26,10 +26,7 @@ import com.duben.happyplaylet.manager.UserManager
...
@@ -26,10 +26,7 @@ import com.duben.happyplaylet.manager.UserManager
import
com.duben.happyplaylet.mvp.model.*
import
com.duben.happyplaylet.mvp.model.*
import
com.duben.happyplaylet.mvp.presenters.HomePresenter
import
com.duben.happyplaylet.mvp.presenters.HomePresenter
import
com.duben.happyplaylet.mvp.views.HomeView
import
com.duben.happyplaylet.mvp.views.HomeView
import
com.duben.happyplaylet.ui.activitys.NineActivity
import
com.duben.happyplaylet.ui.activitys.*
import
com.duben.happyplaylet.ui.activitys.NinePayActivity
import
com.duben.happyplaylet.ui.activitys.RecommendActivity
import
com.duben.happyplaylet.ui.activitys.VipActivity
import
com.duben.happyplaylet.ui.adapter.HomeVideoPageAdapter
import
com.duben.happyplaylet.ui.adapter.HomeVideoPageAdapter
import
com.duben.happyplaylet.ui.adapter.ImageTitleAdapter
import
com.duben.happyplaylet.ui.adapter.ImageTitleAdapter
import
com.duben.happyplaylet.ui.adapter.TopAdapter
import
com.duben.happyplaylet.ui.adapter.TopAdapter
...
@@ -97,7 +94,7 @@ class MainFragment : LazyLoadBaseFragment(), HomeView, View.OnClickListener, OnR
...
@@ -97,7 +94,7 @@ class MainFragment : LazyLoadBaseFragment(), HomeView, View.OnClickListener, OnR
val
bundle
=
Bundle
()
val
bundle
=
Bundle
()
bundle
.
putBoolean
(
VipActivity
.
IS_MAIN
,
true
)
bundle
.
putBoolean
(
VipActivity
.
IS_MAIN
,
true
)
readyGo
(
VipActivity
::
class
.
java
,
bundle
)
readyGo
(
New
VipActivity
::
class
.
java
,
bundle
)
}
}
}
else
{
}
else
{
homePresenter
.
getSoltVedio
()
homePresenter
.
getSoltVedio
()
...
@@ -328,7 +325,7 @@ class MainFragment : LazyLoadBaseFragment(), HomeView, View.OnClickListener, OnR
...
@@ -328,7 +325,7 @@ class MainFragment : LazyLoadBaseFragment(), HomeView, View.OnClickListener, OnR
val
bundle
=
Bundle
()
val
bundle
=
Bundle
()
bundle
.
putBoolean
(
VipActivity
.
IS_MAIN
,
true
)
bundle
.
putBoolean
(
VipActivity
.
IS_MAIN
,
true
)
readyGo
(
VipActivity
::
class
.
java
,
bundle
)
readyGo
(
New
VipActivity
::
class
.
java
,
bundle
)
}
}
}
}
}
}
...
...
video/app/src/main/java/com/duben/happyplaylet/ui/widgets/VipPayCancelDialog.kt
0 → 100644
View file @
6949e49d
package
com.duben.happyplaylet.ui.widgets
import
android.app.Activity
import
android.app.Dialog
import
android.view.Gravity
import
android.view.KeyEvent
import
android.view.View
import
android.view.WindowManager
import
com.duben.happyplaylet.R
import
com.duben.happyplaylet.ui.widgets.countdowntimer.CountDownTimerSupport
class
VipPayCancelDialog
(
val
activity
:
Activity
)
:
Dialog
(
activity
,
R
.
style
.
dialog
)
{
private
val
lp
:
WindowManager
.
LayoutParams
var
timer
:
CountDownTimerSupport
?
=
null
init
{
setContentView
(
R
.
layout
.
dialog_vip_pay_cancel
)
// 设置window属性
lp
=
window
!!
.
attributes
lp
.
gravity
=
Gravity
.
CENTER
lp
.
width
=
WindowManager
.
LayoutParams
.
MATCH_PARENT
lp
.
windowAnimations
=
R
.
style
.
DialogAnimCancel
window
!!
.
attributes
=
lp
// 设置外部不可关闭
setCancelable
(
false
)
setCanceledOnTouchOutside
(
false
)
setOnKeyListener
{
dialogInterface
,
i
,
keyEvent
->
i
==
KeyEvent
.
KEYCODE_BACK
}
findViewById
<
View
>(
R
.
id
.
text_count
).
setOnClickListener
{
dismiss
()
}
}
override
fun
dismiss
()
{
if
(
activity
.
isFinishing
)
return
super
.
dismiss
()
}
override
fun
onDetachedFromWindow
()
{
super
.
onDetachedFromWindow
()
timer
?.
stop
()
timer
=
null
}
}
\ No newline at end of file
video/app/src/main/java/com/duben/library/utils/GlideUtils.kt
View file @
6949e49d
...
@@ -19,6 +19,7 @@ import com.bumptech.glide.request.target.ViewTarget
...
@@ -19,6 +19,7 @@ import com.bumptech.glide.request.target.ViewTarget
import
com.bumptech.glide.request.transition.Transition
import
com.bumptech.glide.request.transition.Transition
import
com.bumptech.glide.signature.ObjectKey
import
com.bumptech.glide.signature.ObjectKey
import
com.duben.happyplaylet.utils.BubbleUtils
import
com.duben.happyplaylet.utils.BubbleUtils
import
jp.wasabeef.glide.transformations.BlurTransformation
/**
/**
* 描述:GlideUtils
* 描述:GlideUtils
...
@@ -67,12 +68,12 @@ object GlideUtils {
...
@@ -67,12 +68,12 @@ object GlideUtils {
//加载Gif*****
//加载Gif*****
fun
loadRoundImageViewGif
(
mContext
:
Context
,
drawable
:
Int
,
imageView
:
ImageView
)
{
fun
loadRoundImageViewGif
(
mContext
:
Context
,
drawable
:
Int
,
imageView
:
ImageView
)
{
val
options
=
RequestOptions
()
val
options
=
RequestOptions
()
.
fitCenter
()
.
fitCenter
()
.
diskCacheStrategy
(
DiskCacheStrategy
.
DATA
)
.
diskCacheStrategy
(
DiskCacheStrategy
.
DATA
)
Glide
.
with
(
mContext
)
Glide
.
with
(
mContext
)
.
load
(
drawable
)
.
load
(
drawable
)
.
apply
(
options
)
.
apply
(
options
)
.
into
(
imageView
)
.
into
(
imageView
)
}
}
//默认加载
//默认加载
...
@@ -199,4 +200,12 @@ object GlideUtils {
...
@@ -199,4 +200,12 @@ object GlideUtils {
.
apply
(
RequestOptions
().
skipMemoryCache
(
true
))
.
apply
(
RequestOptions
().
skipMemoryCache
(
true
))
.
into
(
imageView
)
.
into
(
imageView
)
}
}
//加载毛玻璃图片
fun
loadBlurImageView
(
mContext
:
Context
,
url
:
String
,
imageView
:
ImageView
)
{
Glide
.
with
(
mContext
).
load
(
url
)
.
apply
(
RequestOptions
.
bitmapTransform
(
BlurTransformation
(
25
,
3
)))
.
into
(
imageView
)
}
}
}
\ No newline at end of file
video/app/src/main/res/anim/push_left_out.xml
0 → 100755
View file @
6949e49d
<?xml version="1.0" encoding="utf-8"?>
<set
xmlns:android=
"http://schemas.android.com/apk/res/android"
>
<translate
android:duration=
"500"
android:fromXDelta=
"0"
android:toXDelta=
"-25%p"
/>
<translate
android:duration=
"500"
android:fromYDelta=
"0"
android:toYDelta=
"25%p"
/>
<alpha
android:duration=
"500"
android:fromAlpha=
"1.0"
android:toAlpha=
"0.0"
/>
</set>
\ No newline at end of file
video/app/src/main/res/layout/activity_new_vip.xml
0 → 100644
View file @
6949e49d
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
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"
android:background=
"@color/black"
android:orientation=
"vertical"
>
<androidx.core.widget.NestedScrollView
android:id=
"@+id/nsv"
android:layout_width=
"match_parent"
android:layout_height=
"0dp"
android:layout_weight=
"1"
>
<FrameLayout
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:orientation=
"vertical"
>
<FrameLayout
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
>
<ImageView
android:id=
"@+id/iv_blur"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:scaleType=
"fitXY"
/>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:orientation=
"vertical"
>
<com.youth.banner.Banner
android:id=
"@+id/vip_banner"
android:layout_width=
"match_parent"
android:layout_height=
"200dp"
android:layout_marginTop=
"50dp"
/>
<TextView
android:id=
"@+id/tv_banner_title"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center"
android:layout_marginTop=
"10dp"
android:textColor=
"@color/main_mints"
android:textSize=
"20sp"
/>
<TextView
android:id=
"@+id/tv_banner_info"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center"
android:layout_marginStart=
"20dp"
android:layout_marginTop=
"6dp"
android:layout_marginEnd=
"20dp"
android:ellipsize=
"end"
android:gravity=
"center"
android:maxLines=
"3"
android:textColor=
"@color/btn_enabled"
android:textSize=
"16sp"
/>
</LinearLayout>
</FrameLayout>
<ImageView
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:src=
"@mipmap/bg_vip_top"
/>
<ImageView
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:src=
"@mipmap/bg_vip_top"
/>
<ImageView
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:src=
"@mipmap/bg_vip_top"
/>
</LinearLayout>
<ImageView
android:id=
"@+id/ic_vip_quit"
android:layout_width=
"60dp"
android:layout_height=
"60dp"
android:layout_gravity=
"right"
android:layout_marginTop=
"30dp"
android:layout_marginEnd=
"10dp"
android:padding=
"10dp"
android:scaleType=
"centerCrop"
android:src=
"@mipmap/ic_quit_yuan"
/>
</FrameLayout>
</androidx.core.widget.NestedScrollView>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_gravity=
"bottom"
android:layout_marginBottom=
"30dp"
android:orientation=
"vertical"
>
<androidx.recyclerview.widget.RecyclerView
android:id=
"@+id/rvVip"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center_horizontal"
android:background=
"@null"
android:overScrollMode=
"never"
/>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:orientation=
"horizontal"
>
<LinearLayout
android:id=
"@+id/ll_vip_alipay"
android:layout_width=
"0dp"
android:layout_height=
"40dp"
android:layout_weight=
"1"
android:gravity=
"center"
android:orientation=
"horizontal"
android:paddingLeft=
"20dp"
>
<TextView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:drawableLeft=
"@mipmap/ic_alipay"
android:drawablePadding=
"6dp"
android:gravity=
"center_vertical"
android:text=
"支付宝支付"
android:textColor=
"@color/white"
android:textSize=
"14sp"
android:textStyle=
"bold"
/>
<ImageView
android:id=
"@+id/iv_vip_alipay"
android:layout_width=
"30dp"
android:layout_height=
"30dp"
android:scaleType=
"center"
android:src=
"@mipmap/ic_vip_enable_blue"
/>
</LinearLayout>
<LinearLayout
android:id=
"@+id/ll_vip_wx"
android:layout_width=
"0dp"
android:layout_height=
"40dp"
android:layout_weight=
"1"
android:gravity=
"center"
android:orientation=
"horizontal"
android:paddingRight=
"20dp"
>
<TextView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:drawableLeft=
"@mipmap/ic_call_wx"
android:drawablePadding=
"6dp"
android:gravity=
"center_vertical"
android:text=
"微信支付"
android:textColor=
"@color/white"
android:textSize=
"14sp"
android:textStyle=
"bold"
/>
<ImageView
android:id=
"@+id/iv_vip_wx"
android:layout_width=
"30dp"
android:layout_height=
"30dp"
android:scaleType=
"center"
android:src=
"@mipmap/ic_vip_none"
/>
</LinearLayout>
</LinearLayout>
<TextView
android:id=
"@+id/tv_vip_hint"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center_horizontal"
android:text=
"试用到期后将按终身xx元自动续费,可随时关闭"
android:textColor=
"#97ffffff"
android:textSize=
"10sp"
/>
<LinearLayout
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center_horizontal"
android:layout_marginTop=
"6dp"
android:orientation=
"horizontal"
>
<CheckBox
android:id=
"@+id/cbVipAgreement"
style=
"@style/CustomCheckboxTheme"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:checked=
"true"
/>
<TextView
android:id=
"@+id/tvVipAgreement"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginStart=
"6dp"
android:text=
"点击购买即表示您同意《会员付费协议》"
android:textColor=
"@color/white"
android:textSize=
"10sp"
/>
</LinearLayout>
<io.supercharge.shimmerlayout.ShimmerLayout
android:id=
"@+id/shimmer_text"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center_horizontal"
android:layout_marginLeft=
"30dp"
android:layout_marginTop=
"10dp"
android:layout_marginRight=
"30dp"
android:layout_marginBottom=
"10dp"
app:shimmer_animation_duration=
"1200"
app:shimmer_color=
"#50ffffff"
>
<TextView
android:id=
"@+id/tvVipPay"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:background=
"@mipmap/bg_vip_btn"
android:gravity=
"center"
android:text=
"立即开通"
android:textColor=
"@color/white"
android:textSize=
"18sp"
/>
</io.supercharge.shimmerlayout.ShimmerLayout>
</LinearLayout>
</LinearLayout>
\ No newline at end of file
video/app/src/main/res/layout/dialog_vip_pay_cancel.xml
0 → 100644
View file @
6949e49d
<?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"
>
<FrameLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_centerInParent=
"true"
>
<ImageView
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:layout_marginStart=
"30dp"
android:layout_marginEnd=
"30dp"
android:scaleType=
"fitXY"
android:src=
"@mipmap/bg_vip_count"
/>
<LinearLayout
android:id=
"@+id/fm"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginStart=
"30dp"
android:layout_marginEnd=
"30dp"
android:orientation=
"vertical"
>
<TextView
android:id=
"@+id/text_count"
android:layout_width=
"26dp"
android:layout_height=
"26dp"
android:layout_gravity=
"right"
android:layout_margin=
"12dp"
android:background=
"@drawable/shape_vedio"
android:gravity=
"center"
android:text=
"3"
android:textColor=
"#969798"
android:textSize=
"16sp"
/>
<LinearLayout
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center_horizontal"
android:layout_marginTop=
"4dp"
android:orientation=
"horizontal"
>
<TextView
android:id=
"@+id/tv_dialog_vip_count_left"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:text=
"1分钱"
android:textColor=
"#E8541D"
android:textSize=
"22sp"
android:textStyle=
"bold"
/>
<TextView
android:id=
"@+id/tv_dialog_vip_count_right"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:text=
" 签约会员"
android:textColor=
"#2B272D"
android:textSize=
"22sp"
android:textStyle=
"bold"
/>
</LinearLayout>
<TextView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center_horizontal"
android:layout_marginTop=
"10dp"
android:text=
"解锁全部剧集"
android:textColor=
"#2B272D"
android:textSize=
"16sp"
/>
<TextView
android:layout_width=
"200dp"
android:layout_height=
"44dp"
android:layout_gravity=
"center_horizontal"
android:layout_marginTop=
"26dp"
android:layout_marginBottom=
"18dp"
android:background=
"@mipmap/bg_vip_count_btn"
android:gravity=
"center"
android:text=
"解锁"
android:textColor=
"#6C4D22"
android:textSize=
"18sp"
android:textStyle=
"bold"
/>
</LinearLayout>
</FrameLayout>
</RelativeLayout>
video/app/src/main/res/values/styles.xml
View file @
6949e49d
...
@@ -83,6 +83,11 @@
...
@@ -83,6 +83,11 @@
<item
name=
"android:windowExitAnimation"
>
@anim/fade_out
</item>
<item
name=
"android:windowExitAnimation"
>
@anim/fade_out
</item>
</style>
</style>
<style
name=
"DialogAnimCancel"
parent=
"@android:style/Animation"
>
<item
name=
"android:windowEnterAnimation"
>
@anim/fade_in
</item>
<item
name=
"android:windowExitAnimation"
>
@anim/push_left_out
</item>
</style>
<style
name=
"CustomCheckboxTheme"
parent=
"@android:style/Widget.CompoundButton.CheckBox"
>
<style
name=
"CustomCheckboxTheme"
parent=
"@android:style/Widget.CompoundButton.CheckBox"
>
<item
name=
"android:button"
>
@drawable/checkbox_style
</item>
<item
name=
"android:button"
>
@drawable/checkbox_style
</item>
</style>
</style>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment