diff --git a/app/src/main/java/com/yizhuan/erban/avroom/anotherroompk/RoomPKCreateActivity.kt b/app/src/main/java/com/yizhuan/erban/avroom/anotherroompk/RoomPKCreateActivity.kt index e2b450e51..64328905a 100644 --- a/app/src/main/java/com/yizhuan/erban/avroom/anotherroompk/RoomPKCreateActivity.kt +++ b/app/src/main/java/com/yizhuan/erban/avroom/anotherroompk/RoomPKCreateActivity.kt @@ -129,7 +129,7 @@ class RoomPKCreateActivity : BaseViewBindingActivity(R.id.tv_select) diff --git a/app/src/main/java/com/yizhuan/erban/ui/user/adapter/CommonWrapIndicatorAdapter.java b/app/src/main/java/com/yizhuan/erban/ui/user/adapter/CommonWrapIndicatorAdapter.java new file mode 100644 index 000000000..4c0354251 --- /dev/null +++ b/app/src/main/java/com/yizhuan/erban/ui/user/adapter/CommonWrapIndicatorAdapter.java @@ -0,0 +1,104 @@ +package com.yizhuan.erban.ui.user.adapter; + +import android.content.Context; +import android.view.Gravity; +import android.view.ViewGroup; +import android.widget.FrameLayout; +import android.widget.TextView; + +import androidx.core.content.ContextCompat; + +import com.yizhuan.erban.R; +import com.yizhuan.erban.ui.widget.XRecyclerView.ScaleTransitionPagerTitleView; +import com.yizhuan.erban.ui.widget.magicindicator.buildins.UIUtil; +import com.yizhuan.erban.ui.widget.magicindicator.buildins.commonnavigator.abs.CommonNavigatorAdapter; +import com.yizhuan.erban.ui.widget.magicindicator.buildins.commonnavigator.abs.IPagerIndicator; +import com.yizhuan.erban.ui.widget.magicindicator.buildins.commonnavigator.abs.IPagerTitleView; +import com.yizhuan.erban.ui.widget.magicindicator.buildins.commonnavigator.indicators.GradientLinePagerIndicator; +import com.yizhuan.erban.ui.widget.magicindicator.buildins.commonnavigator.indicators.GradientLineRoundPagerIndicator; +import com.yizhuan.erban.ui.widget.magicindicator.buildins.commonnavigator.indicators.LinePagerIndicator; + +import java.util.List; + +public class CommonWrapIndicatorAdapter extends CommonNavigatorAdapter { + private final Context mContext; + private final List mTitleList; + + private int textSize = 18; + private float minScale = 0.75f; + private boolean showIndicator = true; + private OnItemSelectListener mOnItemSelectListener; + + public CommonWrapIndicatorAdapter(Context context, List charSequences) { + this.mContext = context; + this.mTitleList = charSequences; + } + + @Override + public int getCount() { + return mTitleList == null ? 0 : mTitleList.size(); + } + + @Override + public IPagerTitleView getTitleView(Context context, final int i) { + ScaleTransitionPagerTitleView scaleTransitionPagerTitleView = new ScaleTransitionPagerTitleView(context, true); + scaleTransitionPagerTitleView.setNormalColor(ContextCompat.getColor(context, R.color.color_6D6B89)); + scaleTransitionPagerTitleView.setSelectedColor(ContextCompat.getColor(context, R.color.color_1F1A4E)); + scaleTransitionPagerTitleView.setMinScale(minScale); + scaleTransitionPagerTitleView.setTextSize(textSize); + int padding = UIUtil.dip2px(context, 12); + scaleTransitionPagerTitleView.setPadding(padding, 0, padding, 0); + scaleTransitionPagerTitleView.setText(mTitleList.get(i)); + scaleTransitionPagerTitleView.setOnClickListener(view -> { + if (mOnItemSelectListener != null) { + mOnItemSelectListener.onItemSelect(i, scaleTransitionPagerTitleView); + } + + }); + return scaleTransitionPagerTitleView; + } + + @Override + public IPagerIndicator getIndicator(Context context) { + if (!showIndicator) return null; + GradientLineRoundPagerIndicator indicator = new GradientLineRoundPagerIndicator(context); + indicator.setMode(LinePagerIndicator.MODE_EXACTLY); + FrameLayout.LayoutParams lp = new FrameLayout.LayoutParams(ViewGroup.LayoutParams.WRAP_CONTENT, ViewGroup.LayoutParams.WRAP_CONTENT); + lp.gravity = Gravity.END; + lp.bottomMargin = UIUtil.dip2px(mContext, 0); + indicator.setLayoutParams(lp); + return indicator; + } + + public int getTextSize() { + return textSize; + } + + public void setTextSize(int textSize) { + this.textSize = textSize; + } + + public float getMinScale() { + return minScale; + } + + public void setMinScale(float minScale) { + this.minScale = minScale; + } + + public boolean isShowIndicator() { + return showIndicator; + } + + public void setShowIndicator(boolean showIndicator) { + this.showIndicator = showIndicator; + } + + public void setOnItemSelectListener(OnItemSelectListener onItemSelectListener) { + mOnItemSelectListener = onItemSelectListener; + } + + public interface OnItemSelectListener { + void onItemSelect(int position, TextView view); + } +} diff --git a/app/src/main/java/com/yizhuan/erban/ui/user/view/UserInfoGiftWallFragment.kt b/app/src/main/java/com/yizhuan/erban/ui/user/view/UserInfoGiftWallFragment.kt index ef2951fc2..bf5b7e4e0 100644 --- a/app/src/main/java/com/yizhuan/erban/ui/user/view/UserInfoGiftWallFragment.kt +++ b/app/src/main/java/com/yizhuan/erban/ui/user/view/UserInfoGiftWallFragment.kt @@ -9,7 +9,7 @@ import com.yizhuan.erban.R import com.yizhuan.erban.base.BaseViewBindingFragment import com.yizhuan.erban.databinding.FragmentUserinfoGiftWallBinding import com.yizhuan.erban.ui.user.UserInfoGiftFragment -import com.yizhuan.erban.ui.user.adapter.UserInfoIndicatorAdapter +import com.yizhuan.erban.ui.user.adapter.CommonWrapIndicatorAdapter import com.yizhuan.erban.ui.user.adapter.UserInfoPagerAdapter import com.yizhuan.erban.ui.widget.magicindicator.MagicIndicator import com.yizhuan.erban.ui.widget.magicindicator.ViewPagerHelper @@ -42,7 +42,7 @@ class UserInfoGiftWallFragment : BaseViewBindingFragment viewPager.currentItem = position } diff --git a/app/src/main/java/com/yizhuan/erban/ui/widget/magicindicator/buildins/commonnavigator/indicators/GradientLineRoundPagerIndicator.java b/app/src/main/java/com/yizhuan/erban/ui/widget/magicindicator/buildins/commonnavigator/indicators/GradientLineRoundPagerIndicator.java new file mode 100644 index 000000000..3e7d14859 --- /dev/null +++ b/app/src/main/java/com/yizhuan/erban/ui/widget/magicindicator/buildins/commonnavigator/indicators/GradientLineRoundPagerIndicator.java @@ -0,0 +1,28 @@ +package com.yizhuan.erban.ui.widget.magicindicator.buildins.commonnavigator.indicators; + +import android.content.Context; +import android.graphics.Canvas; +import android.graphics.LinearGradient; + +import com.yizhuan.erban.ui.widget.magicindicator.buildins.UIUtil; + +/** + * 实现渐变指示器帮助类 + */ +public class GradientLineRoundPagerIndicator extends LinePagerIndicator { + + private Context mContext; + + public GradientLineRoundPagerIndicator(Context context) { + super(context); + mContext = context; + } + + @Override + protected void onDraw(Canvas canvas) { + LinearGradient lg = new LinearGradient(getLineRect().left, getLineRect().top, getLineRect().right, getLineRect().bottom, new int[]{0xFF13E2F5, 0xFFCC66FF}, null, LinearGradient.TileMode.CLAMP); + getPaint().setShader(lg); + canvas.drawRoundRect(getLineRect(), UIUtil.dip2px(mContext, 2), UIUtil.dip2px(mContext, 2), getPaint()); + } + +} diff --git a/app/src/main/java/com/yizhuan/erban/ui/widget/magicindicator/buildins/commonnavigator/indicators/LinePagerIndicator.java b/app/src/main/java/com/yizhuan/erban/ui/widget/magicindicator/buildins/commonnavigator/indicators/LinePagerIndicator.java index 5815a019d..8b073bc81 100644 --- a/app/src/main/java/com/yizhuan/erban/ui/widget/magicindicator/buildins/commonnavigator/indicators/LinePagerIndicator.java +++ b/app/src/main/java/com/yizhuan/erban/ui/widget/magicindicator/buildins/commonnavigator/indicators/LinePagerIndicator.java @@ -54,7 +54,7 @@ public class LinePagerIndicator extends View implements IPagerIndicator { mPaint = new Paint(Paint.ANTI_ALIAS_FLAG); mPaint.setStyle(Paint.Style.FILL); mLineHeight = UIUtil.dip2px(context, 3); - mLineWidth = UIUtil.dip2px(context, 10); + mLineWidth = UIUtil.dip2px(context, 15); } @Override diff --git a/app/src/main/res/drawable/bg_ffffff_8.xml b/app/src/main/res/drawable/bg_ffffff_8.xml new file mode 100644 index 000000000..293b10737 --- /dev/null +++ b/app/src/main/res/drawable/bg_ffffff_8.xml @@ -0,0 +1,9 @@ + + + + + + + + \ No newline at end of file diff --git a/app/src/main/res/layout/fragment_userinfo_gift_wall.xml b/app/src/main/res/layout/fragment_userinfo_gift_wall.xml index 04c059c85..342e2c0bd 100644 --- a/app/src/main/res/layout/fragment_userinfo_gift_wall.xml +++ b/app/src/main/res/layout/fragment_userinfo_gift_wall.xml @@ -9,7 +9,7 @@ android:layout_height="wrap_content" android:layout_marginStart="@dimen/dp_7" android:layout_marginEnd="@dimen/dp_7" - android:background="@drawable/bg_user_info_skill" + android:background="@drawable/bg_ffffff_8" android:orientation="vertical" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintTop_toTopOf="parent" @@ -18,7 +18,7 @@ diff --git a/app/src/main/res/layout/fragment_userinfo_userinfo.xml b/app/src/main/res/layout/fragment_userinfo_userinfo.xml index fea1ee7bd..1df21a733 100644 --- a/app/src/main/res/layout/fragment_userinfo_userinfo.xml +++ b/app/src/main/res/layout/fragment_userinfo_userinfo.xml @@ -15,7 +15,7 @@ android:layout_height="wrap_content" android:layout_marginLeft="@dimen/dp_7" android:layout_marginRight="@dimen/dp_7" - android:background="@drawable/bg_user_info_skill" + android:background="@drawable/bg_ffffff_8" android:orientation="vertical" android:paddingLeft="@dimen/dp_20" android:paddingTop="@dimen/dp_18" @@ -47,7 +47,7 @@ android:layout_height="wrap_content" android:layout_marginStart="@dimen/dp_7" android:layout_marginEnd="@dimen/dp_7" - android:background="@drawable/bg_user_info_skill" + android:background="@drawable/bg_ffffff_8" android:orientation="vertical" android:paddingStart="20dp" android:paddingTop="18dp" @@ -285,7 +285,7 @@ android:layout_height="90dp" android:layout_marginStart="@dimen/dp_7" android:layout_marginEnd="@dimen/dp_7" - android:background="@drawable/bg_user_info_skill" + android:background="@drawable/bg_ffffff_8" android:orientation="vertical" android:paddingStart="20dp" android:paddingTop="18dp" diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 035a6d3c7..02370966e 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -160,7 +160,7 @@ - Peko號:%d + ID:%d 我的關註 我的粉絲 @@ -369,7 +369,7 @@ 查看傷害排行榜 獲得獎勵(%s) 鉆石 - Peko號:%s + ID:%s 傷害 %s 點/次 (%s鉆石) 鉆石可以兌換鉆石,兌換比率:1鉆石=%s鉆石;\n @@ -866,12 +866,12 @@ 鉆石轉贈 受贈人 - 請輸入手機號/Peko號 + 請輸入手機號/ID 轉贈金額 自定義輸入 立即轉贈 我的轉贈記錄 - %1$s (Peko號: %2$s) + %1$s (ID: %2$s) 返回登錄頁 隱私設置 @@ -1010,7 +1010,7 @@ 播放出錯,請重試 房間ID: 房間人數: - Peko號: + ID: 公會 公會ID: 公會人數: @@ -2053,7 +2053,7 @@ 等人中 熱門進入房間 成功進入收藏的房間 - Peko號: + ID: Ta給你發送了一條消息~ Ta們向你發送了多條消息~ 暫無未讀消息需要清理 @@ -2375,7 +2375,7 @@ 暫未達到可發起私聊等級 財富等級≥ 魅力等級≥ - Peko號: + ID: 界面已銷毀 路徑錯誤 路徑錯誤 @@ -2771,7 +2771,7 @@ 已關註Ta 關註Ta 數據加載中,請稍後... - Peko號: + ID: 粉絲 獲取用戶房間信息異常。 獲取用戶房間信息異常。 @@ -2988,7 +2988,7 @@ 跨房PK 選擇PK對象 廳的名字000 - Peko號:1234 + ID:1234 選擇PK時長 10分鐘 20分鐘 @@ -2998,7 +2998,7 @@ PK玩法 選填,10個字以內 發起挑戰 - 請輸入Peko號 + 請輸入ID 確認選擇 房間的背景 房間名 @@ -3028,7 +3028,7 @@ 主播PK 選擇PK對象: 廳的名字000 - Peko號:1234 + ID:1234 選擇PK時長: 10分鐘 20分鐘 @@ -3038,7 +3038,7 @@ PK玩法: 選填,10個字以內 發起挑戰 - 請輸入Peko號 + 請輸入ID 點擊進入更多精彩 常見問題 群主 @@ -3057,7 +3057,7 @@ 驗證碼: 請輸入驗證碼 下一步 - 如果您的手機號已丟失\n請咨詢客服,Peko號:88001 + 如果您的手機號已丟失\n請咨詢客服,ID:88001 請綁定你的支付寶賬號 羅生 鉆石余額 @@ -3376,7 +3376,7 @@ 2017年9月11日 曾經看過的人 黨移動黨移動地下黨黨移動地下黨黨移動地下黨地下黨 - Peko號:123456 + ID:123456 摩羯座 神皇 2017年9月11日 @@ -3401,7 +3401,7 @@ 所屬房間 忘忘憂忘忘憂閣忘憂閣憂閣閣忘憂閣憂閣 公會ID:123456 - Peko號:1234567 + ID:1234567 房間人數:123 申請加入 技能卡 @@ -3411,7 +3411,7 @@ 公會人數:123 公會數量:123 公會ID:123456 - Peko號:1234567 + ID:1234567 房間人數:123 念一下這句話吧念一下這句話吧念一下這句話吧 恭喜「Tm.八米大雕青木」保皇成功,哈啊啊啊啊啊啊啊啊啊啊啊 @@ -3511,7 +3511,7 @@ 房間名稱房間名稱房間名稱 房間名稱 交友廳官方交友廳交友廳官方交友廳 - Peko號:1234567 + ID:1234567 37分鐘前看過你 紅隊 狐仙嘎嘎 @@ -3602,7 +3602,7 @@ PK中 余生點唱歌曲交友房間 廳的名字000 - Peko號:1234 + ID:1234 這是房間標題這是房間標題 距離上一名 碰碰我最強 @@ -3610,7 +3610,7 @@ 什麽也沒留下 想和大家來聊一聊,有人來聊聊聊聊聊嗎? 廳的名字000 - Peko號:1234 + ID:1234 選擇 QQ區 名稱 @@ -3815,7 +3815,7 @@ +68元 首頁 我的我的我的我的我的我的 - Peko號:666666 + ID:666666 哈哈哈哈 你好啊啊啊啊啊啊啊啊 我是內容 @@ -4074,7 +4074,7 @@ 沒有搜到相關消息 請輸入搜索內容 我的廳入口 - Peko號: + ID: 公會房間( 公會房間數量: 模廳成員加載失敗... @@ -4208,7 +4208,7 @@ 退出群 解散群將會清除所有群聊信息,確認解散嗎? 退出群將會清除群聊信息,確認退出嗎? - 搜索用戶昵稱/Peko號 + 搜索用戶昵稱/ID 總人數:0人 2019年 01月01日 @@ -4244,7 +4244,7 @@ 管理 哈哈哈哈 退出房間 - 搜索用戶昵稱/Peko號 + 搜索用戶昵稱/ID 已選擇人數 : 5人 2019年 01月01日 @@ -4254,7 +4254,7 @@ 昵稱 主播(鉆石) 房間(鉆石) - 請輸入公會成員Peko號 + 請輸入公會成員ID 添加公會超管 確認 150字內 @@ -4314,7 +4314,7 @@ 峨眉峨眉派派 女神沒有大長腿 公會會長 - Peko號:886887 + ID:886887 公會房間數量:11 管理的房間 小澀瑤小澀瑤小澀瑤 @@ -4749,7 +4749,7 @@ 好友 粉絲 關註 - Peko號: + ID: 界面已銷毀 你還沒有聊天記錄哦!\n快去和好友聊天吧! 刪除該聊天 diff --git a/app/src/module_community/res/drawable-xhdpi/icon_square_dynamic_like_normal.png b/app/src/module_community/res/drawable-xhdpi/icon_square_dynamic_like_normal.png deleted file mode 100644 index 11975fb98..000000000 Binary files a/app/src/module_community/res/drawable-xhdpi/icon_square_dynamic_like_normal.png and /dev/null differ diff --git a/app/src/module_community/res/drawable-xhdpi/icon_square_dynamic_like_normal.webp b/app/src/module_community/res/drawable-xhdpi/icon_square_dynamic_like_normal.webp new file mode 100644 index 000000000..ddf8316d5 Binary files /dev/null and b/app/src/module_community/res/drawable-xhdpi/icon_square_dynamic_like_normal.webp differ diff --git a/app/src/module_community/res/layout/item_userinfo_dynamic.xml b/app/src/module_community/res/layout/item_userinfo_dynamic.xml index 20775df38..dd8294c4a 100644 --- a/app/src/module_community/res/layout/item_userinfo_dynamic.xml +++ b/app/src/module_community/res/layout/item_userinfo_dynamic.xml @@ -4,7 +4,7 @@ xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="wrap_content" - android:background="@drawable/bg_user_info_skill" + android:background="@drawable/bg_ffffff_8" android:orientation="vertical"> (R.id.rv_room) diff --git a/gradle.properties b/gradle.properties index bba8b643d..841f25d4d 100644 --- a/gradle.properties +++ b/gradle.properties @@ -24,5 +24,5 @@ only_arm64=false channel_file=channel.txt -version_name=1.0.3 -version_code=103 \ No newline at end of file +version_name=1.0.4 +version_code=104 \ No newline at end of file