Merge remote-tracking branch 'origin/dev' into dev

This commit is contained in:
tongchenfei
2020-11-25 20:01:54 +08:00
124 changed files with 80 additions and 63 deletions

View File

@@ -77,6 +77,11 @@ public class CustomRatingBar extends LinearLayout {
* */
private StepSize stepSize;
/*
*添加资源(空白心是白色还是灰色自定义属性)
* */
private boolean otherHeartImg;
@Override
public boolean isClickable() {
return mClickable;
@@ -159,14 +164,21 @@ public class CustomRatingBar extends LinearLayout {
context.getResources().getDimension(R.dimen.heart_ratingbar_height));
elementPadding = mTypedArray.getDimension(R.styleable.CustomRatingBar_elenmentPadding,
context.getResources().getDimension(R.dimen.ratingbar_padding));
/*
* 白天模式下 热心指数(白色)和个人中心(灰色)使用不同的资源
* 默认灰色
* */
otherHeartImg = mTypedArray.getBoolean(R.styleable.CustomRatingBar_OtherHeartImg, true);
elementStep = mTypedArray.getFloat(R.styleable.CustomRatingBar_elenmentStep, 1.0f);
stepSize = StepSize.fromStep(mTypedArray.getInt(R.styleable.CustomRatingBar_stepSize, 1));
elementCount = mTypedArray.getInteger(R.styleable.CustomRatingBar_elenmentCount, 5);
stepSize = StepSize.Half;
Drawable drawable_empty_default = ContextCompat.getDrawable(context, R.drawable.icon_heart_unchoose);
Drawable drawable_harf_default = ContextCompat.getDrawable(context, R.drawable.icon_heart_second);
Drawable drawable_empty_default = ContextCompat.getDrawable(context,
otherHeartImg == false ? R.drawable.icon_heart_unchoose : R.drawable.icon_heart_unchoose_other);
Drawable drawable_half_default = ContextCompat.getDrawable(context,
otherHeartImg == false ? R.drawable.icon_heart_second : R.drawable.icon_heart_second_other);
Drawable drawable_fill_default = ContextCompat.getDrawable(context, R.drawable.icon_heart_choose);
Drawable drawable_empty = mTypedArray.getDrawable(R.styleable.CustomRatingBar_elenmentEmpty);
@@ -175,7 +187,7 @@ public class CustomRatingBar extends LinearLayout {
elementEmptyDrawable = drawable_empty != null ? drawable_empty : drawable_empty_default;
elementFillDrawable = drawable_half != null ? drawable_half : drawable_fill_default;
elementHarfDrawable = drawable_fill != null ? drawable_fill : drawable_harf_default;
elementHarfDrawable = drawable_fill != null ? drawable_fill : drawable_half_default;
mClickable = mTypedArray.getBoolean(R.styleable.CustomRatingBar_clickable, false);
mTypedArray.recycle();
for (int i = 0; i < elementCount; ++i) {

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 822 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 771 B

View File

@@ -38,6 +38,7 @@
<enum name="Half" value="0" />
<enum name="Full" value="1" />
</attr>
<attr name="OtherHeartImg" format="boolean" />
</declare-styleable>
</resources>

View File

@@ -1,5 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<style name="BaseFloatDialogStyle" parent="@android:style/Theme.Dialog">
<item name="android:windowIsFloating">true</item>
<item name="android:windowFrame">@null</item>
@@ -15,8 +16,6 @@
<item name="android:borderlessButtonStyle">@android:color/transparent</item>
</style>
<style name="customHeartHeartRatingBarStyle" parent="@style/Widget.AppCompat.RatingBar">
<item name="android:maxWidth">@dimen/heart_ratingbar_width</item>
<item name="android:minWidth">@dimen/heart_ratingbar_width</item>
@@ -28,5 +27,4 @@
<item name="android:progressDrawable">@drawable/module_commons_heart_ratingbar_drawable</item>
</style>
</resources>

View File

@@ -32,53 +32,53 @@ public class CarIconDisplayStrategy {
// F 系列才有这个帧动画
public static final int[] sFrame = {
R.drawable.v_to_x_warning_circle_orange_00000,
R.drawable.v_to_x_warning_circle_orange_00001,
R.drawable.v_to_x_warning_circle_orange_00002,
R.drawable.v_to_x_warning_circle_orange_00003,
R.drawable.v_to_x_warning_circle_orange_00004,
R.drawable.v_to_x_warning_circle_orange_00005,
R.drawable.v_to_x_warning_circle_orange_00006,
R.drawable.v_to_x_warning_circle_orange_00007,
R.drawable.v_to_x_warning_circle_orange_00008,
R.drawable.v_to_x_warning_circle_orange_00009,
R.drawable.v_to_x_warning_circle_orange_00010,
R.drawable.v_to_x_warning_circle_orange_00011,
R.drawable.v_to_x_warning_circle_orange_00012,
R.drawable.v_to_x_warning_circle_orange_00013,
R.drawable.v_to_x_warning_circle_orange_00014,
R.drawable.v_to_x_warning_circle_orange_00015,
R.drawable.v_to_x_warning_circle_orange_00016,
R.drawable.v_to_x_warning_circle_orange_00017,
R.drawable.v_to_x_warning_circle_orange_00018,
R.drawable.v_to_x_warning_circle_orange_00019,
R.drawable.v_to_x_warning_circle_orange_00020,
R.drawable.v_to_x_warning_circle_orange_00023,
R.drawable.v_to_x_warning_circle_orange_00024,
R.drawable.v_to_x_warning_circle_orange_00025,
R.drawable.v_to_x_warning_circle_orange_00026,
R.drawable.v_to_x_warning_circle_orange_00027,
R.drawable.v_to_x_warning_circle_orange_00028,
R.drawable.v_to_x_warning_circle_orange_00029,
R.drawable.v_to_x_warning_circle_orange_00030,
R.drawable.v_to_x_warning_circle_orange_00031,
R.drawable.v_to_x_warning_circle_orange_00032,
R.drawable.v_to_x_warning_circle_orange_00033,
R.drawable.v_to_x_warning_circle_orange_00034,
R.drawable.v_to_x_warning_circle_orange_00035,
R.drawable.v_to_x_warning_circle_orange_00036,
R.drawable.v_to_x_warning_circle_orange_00037,
R.drawable.v_to_x_warning_circle_orange_00038,
R.drawable.v_to_x_warning_circle_orange_00039,
R.drawable.v_to_x_warning_circle_orange_00040,
R.drawable.v_to_x_warning_circle_orange_00041,
R.drawable.v_to_x_warning_circle_orange_00042,
R.drawable.v_to_x_warning_circle_orange_00043,
R.drawable.v_to_x_warning_circle_orange_00044,
R.drawable.v_to_x_warning_circle_orange_00045,
R.drawable.v_to_x_warning_circle_orange_00046,
R.drawable.v_to_x_warning_circle_orange_00047,
R.drawable.v_to_x_warning_circle_orange_00048
R.drawable.module_service_ic_warning_circle_orange_00000,
R.drawable.module_service_ic_warning_circle_orange_00001,
R.drawable.module_service_ic_warning_circle_orange_00002,
R.drawable.module_service_ic_warning_circle_orange_00003,
R.drawable.module_service_ic_warning_circle_orange_00004,
R.drawable.module_service_ic_warning_circle_orange_00005,
R.drawable.module_service_ic_warning_circle_orange_00006,
R.drawable.module_service_ic_warning_circle_orange_00007,
R.drawable.module_service_ic_warning_circle_orange_00008,
R.drawable.module_service_ic_warning_circle_orange_00009,
R.drawable.module_service_ic_warning_circle_orange_00010,
R.drawable.module_service_ic_warning_circle_orange_00011,
R.drawable.module_service_ic_warning_circle_orange_00012,
R.drawable.module_service_ic_warning_circle_orange_00013,
R.drawable.module_service_ic_warning_circle_orange_00014,
R.drawable.module_service_ic_warning_circle_orange_00015,
R.drawable.module_service_ic_warning_circle_orange_00016,
R.drawable.module_service_ic_warning_circle_orange_00017,
R.drawable.module_service_ic_warning_circle_orange_00018,
R.drawable.module_service_ic_warning_circle_orange_00019,
R.drawable.module_service_ic_warning_circle_orange_00020,
R.drawable.module_service_ic_warning_circle_orange_00021,
R.drawable.module_service_ic_warning_circle_orange_00022,
R.drawable.module_service_ic_warning_circle_orange_00023,
R.drawable.module_service_ic_warning_circle_orange_00024,
R.drawable.module_service_ic_warning_circle_orange_00025,
R.drawable.module_service_ic_warning_circle_orange_00026,
R.drawable.module_service_ic_warning_circle_orange_00027,
R.drawable.module_service_ic_warning_circle_orange_00028,
R.drawable.module_service_ic_warning_circle_orange_00029,
R.drawable.module_service_ic_warning_circle_orange_00030,
R.drawable.module_service_ic_warning_circle_orange_00031,
R.drawable.module_service_ic_warning_circle_orange_00032,
R.drawable.module_service_ic_warning_circle_orange_00033,
R.drawable.module_service_ic_warning_circle_orange_00034,
R.drawable.module_service_ic_warning_circle_orange_00035,
R.drawable.module_service_ic_warning_circle_orange_00036,
R.drawable.module_service_ic_warning_circle_orange_00037,
R.drawable.module_service_ic_warning_circle_orange_00038,
R.drawable.module_service_ic_warning_circle_orange_00039,
R.drawable.module_service_ic_warning_circle_orange_00040,
R.drawable.module_service_ic_warning_circle_orange_00041,
R.drawable.module_service_ic_warning_circle_orange_00042,
R.drawable.module_service_ic_warning_circle_orange_00043,
R.drawable.module_service_ic_warning_circle_orange_00044,
R.drawable.module_service_ic_warning_circle_orange_00045,
R.drawable.module_service_ic_warning_circle_orange_00046
};
private static volatile CarIconDisplayStrategy sInstance;

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.6 KiB

Some files were not shown because too many files have changed in this diff Show More