[Modify]寻爱之旅消耗钻石改为可配置
This commit is contained in:
6
app/src/main/res/color/color_open_box_selector.xml
Normal file
6
app/src/main/res/color/color_open_box_selector.xml
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android" >
|
||||
<item android:state_pressed="true" android:color="@color/color_7B3700"/>
|
||||
<item android:state_focused="true" android:color="@color/color_7B3700"/>
|
||||
<item android:color="@color/color_DF7604"/>
|
||||
</selector>
|
@@ -661,5 +661,7 @@
|
||||
<color name="color_59fdff">#59fdff</color>
|
||||
<color name="color_ffe8aa">#ffe8aa</color>
|
||||
<color name="color_F8FF7B">#F8FF7B</color>
|
||||
<color name="color_DF7604">#DF7604</color>
|
||||
<color name="color_7B3700">#7B3700</color>
|
||||
|
||||
</resources>
|
||||
|
@@ -29,7 +29,6 @@ import com.yizhuan.erban.ui.utils.ImageLoadUtils;
|
||||
import com.yizhuan.erban.utils.UserUtils;
|
||||
import com.yizhuan.treasure_box.bean.PrizeNewInfo;
|
||||
import com.yizhuan.treasure_box.model.BoxModel;
|
||||
import com.yizhuan.treasure_box.model.IBoxModel;
|
||||
import com.yizhuan.xchat_android_core.DemoCache;
|
||||
import com.yizhuan.xchat_android_core.exception.FailReasonException;
|
||||
import com.yizhuan.xchat_android_core.manager.AvRoomDataManager;
|
||||
@@ -60,6 +59,7 @@ public class TreasureBoxActivity extends BaseBindingActivity<ActivityTreasureBox
|
||||
private ObjectAnimator translationYAnimator;
|
||||
private int height;
|
||||
private int sendMessageSwitchLevel;
|
||||
private int price;
|
||||
|
||||
public static void start(Context context) {
|
||||
Intent starter = new Intent(context, TreasureBoxActivity.class);
|
||||
@@ -122,7 +122,7 @@ public class TreasureBoxActivity extends BaseBindingActivity<ActivityTreasureBox
|
||||
@Override
|
||||
public void onSoftKeyboardClosed() {
|
||||
int num = StringUtils.toInt(mBinding.editNum.getText().toString(), 0);
|
||||
if(num == 0){
|
||||
if (num == 0) {
|
||||
mBinding.editNum.setText("1");
|
||||
mBinding.editNum.setSelection(1);
|
||||
}
|
||||
@@ -130,9 +130,12 @@ public class TreasureBoxActivity extends BaseBindingActivity<ActivityTreasureBox
|
||||
});
|
||||
}
|
||||
|
||||
@SuppressLint("CheckResult")
|
||||
@SuppressLint({"CheckResult", "ClickableViewAccessibility"})
|
||||
private void loadKeyInfo() {
|
||||
sendMessageSwitchLevel = AvRoomDataManager.get().mFindLoveSwitchVo.getSendMsgLevel();
|
||||
price = (int) AvRoomDataManager.get().mFindLoveSwitchVo.getPrice();
|
||||
mBinding.tvDiamond.setText(getString(R.string.text_diamond, price));
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 25 KiB After Width: | Height: | Size: 19 KiB |
Binary file not shown.
Before Width: | Height: | Size: 23 KiB After Width: | Height: | Size: 17 KiB |
@@ -173,6 +173,18 @@
|
||||
app:layout_constraintEnd_toEndOf="@id/view_bg"
|
||||
app:layout_constraintStart_toStartOf="@id/view_bg" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/tv_diamond"
|
||||
android:textSize="@dimen/sp_10"
|
||||
android:textColor="@color/color_DF7604"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="@dimen/dp_10"
|
||||
app:layout_constraintStart_toStartOf="@+id/iv_open"
|
||||
app:layout_constraintEnd_toEndOf="@+id/iv_open"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/iv_open"
|
||||
tools:text="1000钻/次"/>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_prize_hint"
|
||||
android:layout_width="wrap_content"
|
||||
|
@@ -7,4 +7,5 @@
|
||||
<string name="text_more_load_end">沒有更多數據</string>
|
||||
<string name="text_more_load_failed">加載失敗,請點我重試</string>
|
||||
<string name="text_more_loading">正在加載中…</string>
|
||||
<string name="text_diamond">%d鉆/次</string>
|
||||
</resources>
|
@@ -9,6 +9,7 @@ public class FindLoveSwitchVo implements Parcelable, Serializable {
|
||||
private boolean open;
|
||||
private int openLevel;
|
||||
private int sendMsgLevel;
|
||||
private double price;
|
||||
|
||||
public boolean isOpen() {
|
||||
return open;
|
||||
@@ -34,10 +35,19 @@ public class FindLoveSwitchVo implements Parcelable, Serializable {
|
||||
this.sendMsgLevel = sendMsgLevel;
|
||||
}
|
||||
|
||||
public double getPrice() {
|
||||
return price;
|
||||
}
|
||||
|
||||
public void setPrice(double price) {
|
||||
this.price = price;
|
||||
}
|
||||
|
||||
protected FindLoveSwitchVo(Parcel in) {
|
||||
open = in.readByte() != 0;
|
||||
openLevel = in.readInt();
|
||||
sendMsgLevel = in.readInt();
|
||||
price = in.readDouble();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -45,6 +55,7 @@ public class FindLoveSwitchVo implements Parcelable, Serializable {
|
||||
dest.writeByte((byte) (open ? 1 : 0));
|
||||
dest.writeInt(openLevel);
|
||||
dest.writeInt(sendMsgLevel);
|
||||
dest.writeDouble(price);
|
||||
}
|
||||
|
||||
public static final Creator<FindLoveSwitchVo> CREATOR = new Creator<FindLoveSwitchVo>() {
|
||||
@@ -64,13 +75,13 @@ public class FindLoveSwitchVo implements Parcelable, Serializable {
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "BoxInfo{" +
|
||||
"open=" + open +
|
||||
", openLevel=" + openLevel +
|
||||
", sendMsgLevel='" + sendMsgLevel + '\'' +
|
||||
", price='" + price + '\'' +
|
||||
'}';
|
||||
}
|
||||
}
|
@@ -29,8 +29,8 @@ COMPILE_SDK_VERSION=32
|
||||
MIN_SDK_VERSION=21
|
||||
TARGET_SDK_VERSION=32
|
||||
|
||||
version_name=1.8.1
|
||||
version_code=181
|
||||
version_name=1.8.2
|
||||
version_code=182
|
||||
|
||||
#systemProp.https.proxyHost=127.0.0.1
|
||||
#systemProp.https.proxyPort=9999
|
Reference in New Issue
Block a user