fixed ui bug(wrong imageview was sent to updateColorView)

This commit is contained in:
Chumva 2018-03-06 13:52:05 +02:00
parent b41497611f
commit 0c19e1861a

View file

@ -90,9 +90,9 @@ public class EditFavoriteGroupDialogFragment extends MenuBottomSheetDialogFragme
final int themeRes = nightMode ? R.style.OsmandDarkTheme : R.style.OsmandLightTheme; final int themeRes = nightMode ? R.style.OsmandDarkTheme : R.style.OsmandLightTheme;
final View changeColorView = View.inflate(new ContextThemeWrapper(getContext(), themeRes), final View changeColorView = View.inflate(new ContextThemeWrapper(getContext(), themeRes),
R.layout.change_fav_color, null); R.layout.change_fav_color, null);
ImageView colorIcon = ((ImageView) changeColorView.findViewById(R.id.change_color_icon)); ((ImageView) changeColorView.findViewById(R.id.change_color_icon))
colorIcon.setImageDrawable(getContentIcon(R.drawable.ic_action_appearance)); .setImageDrawable(getContentIcon(R.drawable.ic_action_appearance));
updateColorView(colorIcon); updateColorView((ImageView) changeColorView.findViewById(R.id.colorImage));
BaseBottomSheetItem changeColorItem = new BaseBottomSheetItem.Builder() BaseBottomSheetItem changeColorItem = new BaseBottomSheetItem.Builder()
.setCustomView(changeColorView) .setCustomView(changeColorView)
.setOnClickListener(new View.OnClickListener() { .setOnClickListener(new View.OnClickListener() {