diff --git a/app/src/main/java/org/mozilla/fenix/components/toolbar/ToolbarIntegration.kt b/app/src/main/java/org/mozilla/fenix/components/toolbar/ToolbarIntegration.kt
index 1b5dec7cd8..030571d868 100644
--- a/app/src/main/java/org/mozilla/fenix/components/toolbar/ToolbarIntegration.kt
+++ b/app/src/main/java/org/mozilla/fenix/components/toolbar/ToolbarIntegration.kt
@@ -5,6 +5,8 @@
package org.mozilla.fenix.components.toolbar
import android.content.Context
+import android.graphics.PorterDuff
+import androidx.core.content.ContextCompat
import androidx.navigation.Navigation
import mozilla.components.browser.domains.autocomplete.DomainAutocompleteProvider
import mozilla.components.browser.session.SessionManager
@@ -13,11 +15,10 @@ import mozilla.components.browser.toolbar.BrowserToolbar
import mozilla.components.concept.storage.HistoryStorage
import mozilla.components.feature.toolbar.ToolbarAutocompleteFeature
import mozilla.components.feature.toolbar.ToolbarFeature
-import org.mozilla.fenix.DefaultThemeManager
import mozilla.components.support.base.feature.LifecycleAwareFeature
+import org.mozilla.fenix.DefaultThemeManager
import org.mozilla.fenix.R
import org.mozilla.fenix.browser.BrowserFragmentDirections
-import org.mozilla.fenix.ext.application
import org.mozilla.fenix.ext.components
class ToolbarIntegration(
@@ -32,19 +33,30 @@ class ToolbarIntegration(
init {
toolbar.setMenuBuilder(toolbarMenu.menuBuilder)
- val home = BrowserToolbar.Button(
- context.resources
- .getDrawable(DefaultThemeManager.resolveAttribute(R.attr.browserToolbarHomeIcon, context),
- context.application.theme),
- context.getString(R.string.browser_home_button),
- visible = { sessionId == null ||
- sessionManager.runWithSession(sessionId) { it.isCustomTabSession().not() } }
- ) {
- Navigation.findNavController(toolbar)
- .navigate(BrowserFragmentDirections.actionBrowserFragmentToHomeFragment())
- }
+ val tabsIcon = context.getDrawable(R.drawable.ic_tabs)
+ tabsIcon?.setColorFilter(
+ ContextCompat.getColor(
+ context,
+ DefaultThemeManager.resolveAttribute(R.attr.browserToolbarIcons, context)
+ ), PorterDuff.Mode.SRC_IN
+ )
+ tabsIcon?.let {
+ val home = BrowserToolbar.Button(
+ it,
+ context.getString(R.string.browser_home_button),
+ visible = {
+ sessionId == null ||
+ sessionManager.runWithSession(sessionId) {
+ it.isCustomTabSession().not()
+ }
+ }
+ ) {
+ Navigation.findNavController(toolbar)
+ .navigate(BrowserFragmentDirections.actionBrowserFragmentToHomeFragment())
+ }
- toolbar.addBrowserAction(home)
+ toolbar.addBrowserAction(home)
+ }
ToolbarAutocompleteFeature(toolbar).apply {
addDomainProvider(domainAutocompleteProvider)
diff --git a/app/src/main/res/drawable/ic_home_white.xml b/app/src/main/res/drawable/ic_home_white.xml
deleted file mode 100644
index d8211bfd39..0000000000
--- a/app/src/main/res/drawable/ic_home_white.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-
-
-
-
-
diff --git a/app/src/main/res/drawable/ic_tabs.xml b/app/src/main/res/drawable/ic_tabs.xml
new file mode 100644
index 0000000000..2ae8871906
--- /dev/null
+++ b/app/src/main/res/drawable/ic_tabs.xml
@@ -0,0 +1,14 @@
+
+
+
+
+
diff --git a/app/src/main/res/values/attrs.xml b/app/src/main/res/values/attrs.xml
index d67149a3dd..6053700f2d 100644
--- a/app/src/main/res/values/attrs.xml
+++ b/app/src/main/res/values/attrs.xml
@@ -34,6 +34,5 @@
-
diff --git a/app/src/main/res/values/styles.xml b/app/src/main/res/values/styles.xml
index f2c0825ee5..a59bf6b440 100644
--- a/app/src/main/res/values/styles.xml
+++ b/app/src/main/res/values/styles.xml
@@ -2,7 +2,7 @@
-
+