For #26644 - Split the Fenix logo in two images

This will allow us applying a certain tint just for the image containing a text
to have a better contrast with wallpapers.
This commit is contained in:
Mugurell 2022-09-15 14:57:28 +03:00 committed by mergify[bot]
parent 74cb0679e2
commit 103a0cb250
18 changed files with 44 additions and 5 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

View File

@ -48,21 +48,39 @@
app:layout_collapseParallaxMultiplier=".167"/>
<!-- This value needs to be 1.67 * the wordmark parallax value as its 24dp vs 40 -->
<ImageView
<LinearLayout
android:id="@+id/wordmark"
android:layout_width="wrap_content"
android:layout_height="40dp"
android:layout_marginStart="16dp"
android:layout_marginTop="18dp"
android:layout_marginBottom="32dp"
android:adjustViewBounds="true"
android:clickable="false"
android:contentDescription="@string/app_name"
android:focusable="false"
android:importantForAccessibility="no"
app:srcCompat="?fenixLogo"
android:orientation="horizontal"
app:layout_collapseMode="parallax"
app:layout_collapseParallaxMultiplier=".1"/>
app:layout_collapseParallaxMultiplier=".1">
<ImageView
android:id="@+id/wordmarkLogo"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_marginEnd="10.dp"
android:adjustViewBounds="true"
android:contentDescription="@null"
app:srcCompat="?fenixWordmarkLogo"
tools:ignore="ImageContrastCheck" />
<ImageView
android:id="@+id/wordmarkText"
android:layout_width="wrap_content"
android:layout_height="@dimen/wordmark_text_height"
android:adjustViewBounds="true"
android:contentDescription="@null"
android:layout_marginTop="@dimen/wordmark_text_margin_top"
app:srcCompat="?fenixWordmarkText" />
</LinearLayout>
</com.google.android.material.appbar.CollapsingToolbarLayout>

View File

@ -4,4 +4,9 @@
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
<resources>
<style name="DialogStyleNormal" parent="DialogStyleDark"/>
<style name="NormalTheme" parent="NormalThemeBase" >
<item name="fenixWordmarkText">@drawable/ic_wordmark_text_private</item>
</style>
</resources>

View File

@ -67,6 +67,8 @@
<attr name="privateBrowsingButtonBackground" format="reference" />
<attr name="privateBrowsingButtonAccent" format="reference" />
<attr name="fenixLogo" format="reference" />
<attr name="fenixWordmarkText" format="reference" />
<attr name="fenixWordmarkLogo" format="reference" />
<attr name="toolbarStartGradient" format="reference"/>
<attr name="toolbarCenterGradient" format="reference"/>
<attr name="toolbarEndGradient" format="reference"/>

View File

@ -78,6 +78,8 @@
<dimen name="home_fragment_top_toolbar_header_margin">60dp</dimen>
<dimen name="home_item_horizontal_margin">16dp</dimen>
<dimen name="home_item_vertical_margin">8dp</dimen>
<dimen name="wordmark_text_height">18dp</dimen>
<dimen name="wordmark_text_margin_top">10dp</dimen>
<!-- Browser Fragment -->
<!--The size of the gap between the tab preview and content layout.-->

View File

@ -119,6 +119,8 @@
<!-- Drawables -->
<item name="fenixLogo">@drawable/ic_logo_wordmark_normal</item>
<item name="fenixWordmarkText">@drawable/ic_wordmark_text_normal</item>
<item name="fenixWordmarkLogo">@drawable/ic_wordmark_logo</item>
<item name="homeBackground">@color/fx_mobile_layer_color_1</item>
<item name="bottomBarBackground">@drawable/home_bottom_bar_background</item>
<item name="bottomBarBackgroundTop">@drawable/home_bottom_bar_background_top</item>
@ -316,6 +318,7 @@
<!-- Drawables -->
<item name="fenixLogo">@drawable/ic_logo_wordmark_private</item>
<item name="fenixWordmarkText">@drawable/ic_wordmark_text_private</item>
<item name="homeBackground">@drawable/private_home_background_gradient</item>
<item name="bottomBarBackground">@drawable/private_home_bottom_bar_background_gradient</item>
<item name="bottomBarBackgroundTop">@drawable/private_home_bottom_bar_background_gradient_top</item>

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

View File

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
<resources>
<!-- Home Fragment -->
<dimen name="wordmark_text_height">28dp</dimen>
<dimen name="wordmark_text_margin_top">12dp</dimen>
</resources>

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.9 KiB