|
@@ -50,7 +50,7 @@ import androidx.fragment.app.Fragment;
|
|
*/
|
|
*/
|
|
@Route(path = RouterPath.MineCenter.HOME_PAGE)
|
|
@Route(path = RouterPath.MineCenter.HOME_PAGE)
|
|
public class HomePageActivity extends BaseMVPActivity<ActivityHomePageNewLayoutBinding, HomePagePresenter> implements HomePageContract.HomePageView, View.OnClickListener {
|
|
public class HomePageActivity extends BaseMVPActivity<ActivityHomePageNewLayoutBinding, HomePagePresenter> implements HomePageContract.HomePageView, View.OnClickListener {
|
|
- public static final String[] titles = new String[]{"个人风采", "陪练课", "直播课", "视频课", "乐谱"};
|
|
|
|
|
|
+ public static final String[] titles = new String[]{"VIP定制课", "趣纠课", "直播课", "视频课", "乐谱"};
|
|
public static final int EXPAND_MODE = 1;
|
|
public static final int EXPAND_MODE = 1;
|
|
public static final int COLLAP_MODE = 2;
|
|
public static final int COLLAP_MODE = 2;
|
|
|
|
|
|
@@ -135,6 +135,8 @@ public class HomePageActivity extends BaseMVPActivity<ActivityHomePageNewLayoutB
|
|
if (tab != null && tab.getCustomView() != null) {
|
|
if (tab != null && tab.getCustomView() != null) {
|
|
View customView = tab.getCustomView();
|
|
View customView = tab.getCustomView();
|
|
TextView tv_text = customView.findViewById(R.id.tv_text);
|
|
TextView tv_text = customView.findViewById(R.id.tv_text);
|
|
|
|
+ View view_indicator = customView.findViewById(R.id.view_indicator);
|
|
|
|
+ view_indicator.setVisibility(View.VISIBLE);
|
|
tv_text.setTextColor(getResources().getColor(com.cooleshow.base.R.color.color_333333));
|
|
tv_text.setTextColor(getResources().getColor(com.cooleshow.base.R.color.color_333333));
|
|
tv_text.setTypeface(Typeface.defaultFromStyle(Typeface.BOLD));
|
|
tv_text.setTypeface(Typeface.defaultFromStyle(Typeface.BOLD));
|
|
tv_text.setTextSize(17);
|
|
tv_text.setTextSize(17);
|
|
@@ -146,6 +148,8 @@ public class HomePageActivity extends BaseMVPActivity<ActivityHomePageNewLayoutB
|
|
if (tab != null && tab.getCustomView() != null) {
|
|
if (tab != null && tab.getCustomView() != null) {
|
|
View customView = tab.getCustomView();
|
|
View customView = tab.getCustomView();
|
|
TextView tv_text = customView.findViewById(R.id.tv_text);
|
|
TextView tv_text = customView.findViewById(R.id.tv_text);
|
|
|
|
+ View view_indicator = customView.findViewById(R.id.view_indicator);
|
|
|
|
+ view_indicator.setVisibility(View.GONE);
|
|
tv_text.setTextColor(getResources().getColor(com.cooleshow.base.R.color.color_666666));
|
|
tv_text.setTextColor(getResources().getColor(com.cooleshow.base.R.color.color_666666));
|
|
tv_text.setTypeface(Typeface.defaultFromStyle(Typeface.NORMAL));
|
|
tv_text.setTypeface(Typeface.defaultFromStyle(Typeface.NORMAL));
|
|
tv_text.setTextSize(15);
|
|
tv_text.setTextSize(15);
|
|
@@ -156,13 +160,13 @@ public class HomePageActivity extends BaseMVPActivity<ActivityHomePageNewLayoutB
|
|
public void onTabReselected(TabLayout.Tab tab) {
|
|
public void onTabReselected(TabLayout.Tab tab) {
|
|
}
|
|
}
|
|
});
|
|
});
|
|
- MineStyleFragment mineStyleFragment = new MineStyleFragment();
|
|
|
|
- SparringCoursePageFragment sparringCoursePageFragment = new SparringCoursePageFragment();
|
|
|
|
|
|
+ VIPCustomCoursePageFragment vipCustomCoursePageFragment = new VIPCustomCoursePageFragment();
|
|
|
|
+ InterestCorrectCoursePageFragment interestCorrectCoursePageFragment = new InterestCorrectCoursePageFragment();
|
|
LiveCoursePageFragment liveCoursePageFragment = new LiveCoursePageFragment();
|
|
LiveCoursePageFragment liveCoursePageFragment = new LiveCoursePageFragment();
|
|
VideoCoursePageFragment videoCoursePageFragment = new VideoCoursePageFragment();
|
|
VideoCoursePageFragment videoCoursePageFragment = new VideoCoursePageFragment();
|
|
mMusicPageFragment = new SheetMusicPageFragment();
|
|
mMusicPageFragment = new SheetMusicPageFragment();
|
|
- fragments.add(mineStyleFragment);
|
|
|
|
- fragments.add(sparringCoursePageFragment);
|
|
|
|
|
|
+ fragments.add(vipCustomCoursePageFragment);
|
|
|
|
+ fragments.add(interestCorrectCoursePageFragment);
|
|
fragments.add(liveCoursePageFragment);
|
|
fragments.add(liveCoursePageFragment);
|
|
fragments.add(videoCoursePageFragment);
|
|
fragments.add(videoCoursePageFragment);
|
|
fragments.add(mMusicPageFragment);
|
|
fragments.add(mMusicPageFragment);
|
|
@@ -239,7 +243,18 @@ public class HomePageActivity extends BaseMVPActivity<ActivityHomePageNewLayoutB
|
|
if (mMusicPageFragment != null) {
|
|
if (mMusicPageFragment != null) {
|
|
mMusicPageFragment.setMusicPersonCertStatus(info.entryStatus);
|
|
mMusicPageFragment.setMusicPersonCertStatus(info.entryStatus);
|
|
}
|
|
}
|
|
- viewBinding.tvIntroduce.setText(info.getIntroduction());
|
|
|
|
|
|
+ if(TextUtils.isEmpty(info.getIntroduction())){
|
|
|
|
+ viewBinding.tvIntroduce.setVisibility(View.GONE);
|
|
|
|
+ viewBinding.selfIntroductionEmpty.setVisibility(View.VISIBLE);
|
|
|
|
+ viewBinding.selfIntroductionEmpty.setOpeBtnClickListener(v -> {
|
|
|
|
+ ARouter.getInstance().build(RouterPath.MineCenter.MINE_STYLE_PAGE)
|
|
|
|
+ .navigation();
|
|
|
|
+ });
|
|
|
|
+ }else{
|
|
|
|
+ viewBinding.tvIntroduce.setText(info.getIntroduction());
|
|
|
|
+ viewBinding.tvIntroduce.setVisibility(View.VISIBLE);
|
|
|
|
+ viewBinding.selfIntroductionEmpty.setVisibility(View.GONE);
|
|
|
|
+ }
|
|
// viewBinding.tvTitle.setText(String.format("%s的主页", info.username));
|
|
// viewBinding.tvTitle.setText(String.format("%s的主页", info.username));
|
|
//星级
|
|
//星级
|
|
if (info.starGrade > 0) {
|
|
if (info.starGrade > 0) {
|