Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
R
RvApp
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
1
Merge Requests
1
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
lify
RvApp
Commits
3fb7cf3c
Commit
3fb7cf3c
authored
Nov 11, 2019
by
linfeng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
音乐功能
parent
ce264934
Changes
4
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
180 additions
and
252 deletions
+180
-252
SelectMusicActivity.java
...ain/java/com/xxrv/video/activity/SelectMusicActivity.java
+107
-251
SelectMusicAdapter.java
.../main/java/com/xxrv/video/adapter/SelectMusicAdapter.java
+45
-0
MusicInfoBean.java
...c/main/java/com/xxrv/video/bean/circle/MusicInfoBean.java
+27
-0
item_trill_music.xml
plugin_video/src/main/res/layout/item_trill_music.xml
+1
-1
No files found.
plugin_video/src/main/java/com/xxrv/video/activity/SelectMusicActivity.java
View file @
3fb7cf3c
This diff is collapsed.
Click to expand it.
plugin_video/src/main/java/com/xxrv/video/adapter/SelectMusicAdapter.java
0 → 100644
View file @
3fb7cf3c
package
com
.
xxrv
.
video
.
adapter
;
import
android.widget.ImageView
;
import
com.chad.library.adapter.base.BaseQuickAdapter
;
import
com.chad.library.adapter.base.BaseViewHolder
;
import
com.ruiwenliu.wrapper.util.glide.GlideManager
;
import
com.xxrv.video.R
;
import
com.xxrv.video.bean.circle.MusicInfo
;
/**
* 音乐选择
*/
public
class
SelectMusicAdapter
extends
BaseQuickAdapter
<
MusicInfo
,
BaseViewHolder
>
{
public
SelectMusicAdapter
()
{
super
(
R
.
layout
.
item_trill_music
);
}
@Override
protected
void
convert
(
BaseViewHolder
helper
,
MusicInfo
item
)
{
helper
.
setText
(
R
.
id
.
tv_name
,
item
.
getName
());
helper
.
setText
(
R
.
id
.
tv_nike_name
,
item
.
getNikeName
());
GlideManager
.
getInstance
(
mContext
).
loadImage
(
item
.
getCover
(),
(
ImageView
)
helper
.
getView
(
R
.
id
.
iv_cover
));
if
(
item
.
state
==
0
)
{
helper
.
setGone
(
R
.
id
.
ll_next
,
false
);
helper
.
setBackgroundRes
(
R
.
id
.
iv_play_state
,
R
.
drawable
.
ic_music_state0
);
}
else
if
(
item
.
state
==
1
)
{
helper
.
setGone
(
R
.
id
.
ll_next
,
true
);
helper
.
setBackgroundRes
(
R
.
id
.
iv_play_state
,
R
.
drawable
.
ic_music_state2
);
}
else
if
(
item
.
state
==
2
)
{
helper
.
setGone
(
R
.
id
.
ll_next
,
false
);
helper
.
setBackgroundRes
(
R
.
id
.
iv_play_state
,
R
.
drawable
.
ic_music_state1
);
}
else
if
(
item
.
state
==
3
)
{
helper
.
setGone
(
R
.
id
.
ll_next
,
true
);
helper
.
setBackgroundRes
(
R
.
id
.
iv_play_state
,
R
.
drawable
.
ic_music_state0
);
}
helper
.
addOnClickListener
(
R
.
id
.
rl_content
);
helper
.
addOnClickListener
(
R
.
id
.
ll_next
);
}
}
plugin_video/src/main/java/com/xxrv/video/bean/circle/MusicInfoBean.java
0 → 100644
View file @
3fb7cf3c
package
com
.
xxrv
.
video
.
bean
.
circle
;
import
com.ruiwenliu.wrapper.base.BaseBean
;
import
java.util.List
;
public
class
MusicInfoBean
extends
BaseBean
{
private
List
<
MusicInfo
>
data
;
private
boolean
rel
;
public
List
<
MusicInfo
>
getData
()
{
return
data
;
}
public
void
setData
(
List
<
MusicInfo
>
data
)
{
this
.
data
=
data
;
}
public
boolean
isRel
()
{
return
rel
;
}
public
void
setRel
(
boolean
rel
)
{
this
.
rel
=
rel
;
}
}
plugin_video/src/main/res/layout/item_trill_music.xml
View file @
3fb7cf3c
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
<LinearLayout
<LinearLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:android=
"http://schemas.android.com/apk/res/android"
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"
match_par
ent"
android:layout_height=
"
wrap_cont
ent"
android:orientation=
"horizontal"
>
android:orientation=
"horizontal"
>
...
...
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