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
882bdd8c
Commit
882bdd8c
authored
Aug 07, 2023
by
jyx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复友盟崩溃问题
parent
338b1c8e
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
8 deletions
+12
-8
VipCountDialog.kt
...ain/java/com/mints/helivideo/ui/widgets/VipCountDialog.kt
+2
-1
RecommendVideoView.java
...java/com/mints/helivideo/video/tx/RecommendVideoView.java
+2
-2
SuperShortVideoView.java
...ava/com/mints/helivideo/video/tx/SuperShortVideoView.java
+7
-4
TXVideoBaseView.java
...in/java/com/mints/helivideo/video/tx/TXVideoBaseView.java
+1
-1
No files found.
video/app/src/main/java/com/mints/helivideo/ui/widgets/VipCountDialog.kt
View file @
882bdd8c
...
...
@@ -19,7 +19,7 @@ import com.mints.helivideo.ui.widgets.countdowntimer.CountDownTimerSupport
import
com.mints.helivideo.ui.widgets.countdowntimer.OnCountDownTimerListener
import
com.mints.helivideo.utils.UIUtils
class
VipCountDialog
(
activity
:
Activity
,
vedioBean
:
VedioBean
,
tipList
:
ArrayList
<
String
>?)
:
class
VipCountDialog
(
val
activity
:
Activity
,
vedioBean
:
VedioBean
,
tipList
:
ArrayList
<
String
>?)
:
Dialog
(
activity
,
R
.
style
.
dialog
)
{
private
val
lp
:
WindowManager
.
LayoutParams
...
...
@@ -81,6 +81,7 @@ class VipCountDialog(activity: Activity, vedioBean: VedioBean, tipList: ArrayLis
}
override
fun
dismiss
()
{
if
(
activity
.
isFinishing
)
return
super
.
dismiss
()
this
.
mOnDialogDismiss
?.
onDialogDismiss
()
}
...
...
video/app/src/main/java/com/mints/helivideo/video/tx/RecommendVideoView.java
View file @
882bdd8c
...
...
@@ -44,7 +44,7 @@ public class RecommendVideoView extends RelativeLayout {
private
int
mCurrentPosition
=
0
;
private
List
<
VideoMultiItemEntity2
>
mList
;
private
List
<
VideoMultiItemEntity2
>
mList
=
new
ArrayList
<>()
;
public
RecommendVideoView
(
Context
context
)
{
this
(
context
,
null
);
...
...
@@ -133,7 +133,7 @@ public class RecommendVideoView extends RelativeLayout {
private
void
onPageSelectedMethod
(
int
position
)
{
if
(
mOnPageChangeListener
!=
null
)
mOnPageChangeListener
.
onPageChange
(
position
);
if
(
position
>=
mList
.
size
()
||
this
.
mList
.
get
(
position
).
getItemType
()
!=
MULTI_ITEM_1
)
{
if
(
mList
==
null
||
position
>=
mList
.
size
()
||
this
.
mList
.
get
(
position
).
getItemType
()
!=
MULTI_ITEM_1
)
{
mBaseItemView
.
stopForPlaying
();
return
;
}
...
...
video/app/src/main/java/com/mints/helivideo/video/tx/SuperShortVideoView.java
View file @
882bdd8c
...
...
@@ -65,6 +65,7 @@ public class SuperShortVideoView extends RelativeLayout {
}
public
void
loadData
(
VedioBean
vedioBean
,
List
<
VideoMultiItemEntity
>
list
,
int
currentPosition
)
{
this
.
mList
.
clear
();
this
.
mList
=
list
;
this
.
mCurrentPosition
=
currentPosition
;
mAdapter
.
setVedioBean
(
vedioBean
);
...
...
@@ -113,7 +114,8 @@ public class SuperShortVideoView extends RelativeLayout {
case
RecyclerView
.
SCROLL_STATE_IDLE
:
//停止滚动
View
view
=
mSnapHelper
.
findSnapView
(
mLayoutManager
);
int
position
=
recyclerView
.
getChildAdapterPosition
(
view
);
if
(
position
==
mCurrentPosition
)
return
;
if
(
position
==
mCurrentPosition
||
position
==
RecyclerView
.
NO_POSITION
)
return
;
Log
.
i
(
TAG
,
"[SCROLL_STATE_IDLE] mLastPositionInIDLE "
+
mLastPositionInIDLE
+
" position "
+
position
);
mCurrentPosition
=
position
;
addAdView
(
position
);
...
...
@@ -218,7 +220,7 @@ public class SuperShortVideoView extends RelativeLayout {
}
public
void
onItemClick
(
final
int
position
)
{
if
(
position
>=
mList
.
size
())
return
;
if
(
mList
==
null
||
position
>=
mList
.
size
())
return
;
mRecyclerView
.
scrollToPosition
(
position
);
mRecyclerView
.
post
(()
->
{
...
...
@@ -231,6 +233,7 @@ public class SuperShortVideoView extends RelativeLayout {
}
public
List
<
VideoMultiItemEntity
>
getData
()
{
if
(
mList
==
null
)
return
new
ArrayList
<>();
return
mList
;
}
...
...
@@ -267,14 +270,14 @@ public class SuperShortVideoView extends RelativeLayout {
}
public
boolean
isAdPosition
(
int
position
)
{
if
(
mList
!=
null
&&
mList
.
size
()
>
0
)
{
if
(
mList
!=
null
&&
mList
.
size
()
>
0
&&
position
<
mList
.
size
()
)
{
return
mList
.
get
(
position
).
getItemType
()
==
MULTI_ITEM_3
;
}
return
false
;
}
public
boolean
isLuckPosition
(
int
position
)
{
if
(
mList
!=
null
&&
mList
.
size
()
>
0
)
{
if
(
mList
!=
null
&&
mList
.
size
()
>
0
&&
position
<
mList
.
size
()
)
{
return
mList
.
get
(
position
).
getItemType
()
==
MULTI_ITEM_2
;
}
return
false
;
...
...
video/app/src/main/java/com/mints/helivideo/video/tx/TXVideoBaseView.java
View file @
882bdd8c
...
...
@@ -103,7 +103,7 @@ public class TXVideoBaseView extends RelativeLayout implements View.OnClickListe
setSeekBarStyle
(
true
);
break
;
case
MotionEvent
.
ACTION_UP
:
if
(
mTXVodPlayerWrapper
.
isPlaying
())
{
if
(
mTXVodPlayerWrapper
!=
null
&&
mTXVodPlayerWrapper
.
isPlaying
())
{
setSeekBarStyle
(
false
);
}
break
;
...
...
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