|
@@ -91,6 +91,17 @@ public class HomeHotMusicSheetItemView extends FrameLayout {
|
|
|
if (mTvUploadAuthor != null) {
|
|
|
mTvUploadAuthor.setText(String.format("上传者:%s", data.addName));
|
|
|
}
|
|
|
+
|
|
|
+ mLlMusicSubject.removeAllViews();
|
|
|
+ if (!TextUtils.isEmpty(data.subjectNames)) {
|
|
|
+ String[] split = data.subjectNames.split(",");
|
|
|
+ if (split != null && split.length > 0) {
|
|
|
+ for (int i = 0; i < split.length; i++) {
|
|
|
+ createSubjectView(split[i]);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
if (TextUtils.equals(data.chargeType, CHARGE_TYPE_FREE)) {
|
|
|
mTvTag.setText("免费");
|
|
|
mTvTag.setTextColor(getContext().getResources().getColor(com.cooleshow.base.R.color.color_01b84f));
|
|
@@ -108,15 +119,6 @@ public class HomeHotMusicSheetItemView extends FrameLayout {
|
|
|
mTvTag.setTextColor(getContext().getResources().getColor(com.cooleshow.base.R.color.color_3591ce));
|
|
|
mTvTag.setBackgroundResource(R.drawable.shape_3591ce_border);
|
|
|
}
|
|
|
- mLlMusicSubject.removeAllViews();
|
|
|
- if (!TextUtils.isEmpty(data.subjectNames)) {
|
|
|
- String[] split = data.subjectNames.split(",");
|
|
|
- if (split != null && split.length > 0) {
|
|
|
- for (int i = 0; i < split.length; i++) {
|
|
|
- createSubjectView(split[i]);
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
}
|
|
|
|
|
|
private void createSubjectView(String text) {
|