Skip to content

Commit

Permalink
For mozilla-mobile#563: Restyles history favicons
Browse files Browse the repository at this point in the history
  • Loading branch information
colintheshots authored and sblatz committed May 13, 2019
1 parent 155353f commit a55481d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,9 @@ class HistoryListItemViewHolder(
favicon.setImageResource(0)
}
} else {
val backgroundTint = DefaultThemeManager.resolveAttribute(R.attr.neutral, itemView.context)
val backgroundTintList = ContextCompat.getColorStateList(itemView.context, backgroundTint)
favicon.backgroundTintList = backgroundTintList
updateFavIcon(item.url)
}
}
Expand Down
3 changes: 2 additions & 1 deletion app/src/main/res/layout/history_list_item.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@
android:id="@+id/history_favicon"
android:layout_width="@dimen/history_favicon_width_height"
android:layout_height="@dimen/history_favicon_width_height"
android:background="@drawable/history_favicon_background"
android:background="@drawable/favicon_background"
android:padding="10dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
Expand Down

0 comments on commit a55481d

Please sign in to comment.