6.5.4礼物冠名
This commit is contained in:
parent
348dca8474
commit
5da8855948
@ -86,6 +86,7 @@ import org.greenrobot.eventbus.EventBus;
|
|||||||
import org.greenrobot.eventbus.Subscribe;
|
import org.greenrobot.eventbus.Subscribe;
|
||||||
import org.greenrobot.eventbus.ThreadMode;
|
import org.greenrobot.eventbus.ThreadMode;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
import java.net.MalformedURLException;
|
import java.net.MalformedURLException;
|
||||||
import java.net.URL;
|
import java.net.URL;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
@ -449,11 +450,14 @@ public class LiveGiftPopup extends AbsDialogFragment {
|
|||||||
goldText.setText(coinModel.getGold());
|
goldText.setText(coinModel.getGold());
|
||||||
diamondText.setText(coinModel.getCoin());
|
diamondText.setText(coinModel.getCoin());
|
||||||
lvStr.setText("Lv." + coinModel.getUserLevel());
|
lvStr.setText("Lv." + coinModel.getUserLevel());
|
||||||
int nextLeve = Integer.parseInt(coinModel.getUserNextLevelRewards());
|
|
||||||
int maxLeve = Integer.parseInt(coinModel.getUserLevelMax()) + Integer.parseInt(coinModel.getUserLevelCurrentConsumption());
|
|
||||||
findViewById(R.id.red_point).setVisibility((!TextUtils.isEmpty(coinModel.getUsersPackRedDot())) &&
|
findViewById(R.id.red_point).setVisibility((!TextUtils.isEmpty(coinModel.getUsersPackRedDot())) &&
|
||||||
TextUtils.equals(coinModel.getUsersPackRedDot(), "1") ? View.VISIBLE : View.GONE);
|
TextUtils.equals(coinModel.getUsersPackRedDot(), "1") ? View.VISIBLE : View.GONE);
|
||||||
if (!TextUtils.equals(coinModel.getUserLevel(), coinModel.getUserLevelMax())) {
|
if (!TextUtils.equals(coinModel.getUserLevel(), coinModel.getUserLevelMax())) {
|
||||||
|
int nextLeve = Integer.parseInt(coinModel.getUserNextLevelRewards());
|
||||||
|
|
||||||
|
|
||||||
|
BigDecimal maxLeve = new BigDecimal(coinModel.getUserLevelMax()).add( new BigDecimal(coinModel.getUserLevelCurrentConsumption()));
|
||||||
try {
|
try {
|
||||||
String leveNext = String.valueOf(nextLeve);
|
String leveNext = String.valueOf(nextLeve);
|
||||||
String userNextLevel = coinModel.getUserLevelUpgrades();
|
String userNextLevel = coinModel.getUserLevelUpgrades();
|
||||||
@ -488,7 +492,7 @@ public class LiveGiftPopup extends AbsDialogFragment {
|
|||||||
Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||||
leaveHint.setText(builder);
|
leaveHint.setText(builder);
|
||||||
progressBar.setProgress(nextLeve);
|
progressBar.setProgress(nextLeve);
|
||||||
progressBar.setMax(maxLeve);
|
progressBar.setMax(maxLeve.intValue());
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw new RuntimeException(e);
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user