Closed Bug 1315348 Opened 8 years ago Closed 8 years ago

Rotating the device while viewing a custom tab loses toolbar color

Categories

(Firefox for Android Graveyard :: General, defect)

All
Android
defect
Not set
normal

Tracking

(firefox52 fixed)

VERIFIED FIXED
Firefox 52
Tracking Status
firefox52 --- fixed

People

(Reporter: droeh, Assigned: droeh)

References

Details

Attachments

(1 file)

Open a custom tab and change the device orientation. The toolbar becomes grey, when it should retain the custom color from the intent (if applicable).
This turned out to be an easy enough fix: just preserve the color and title in onSaveInstanceState and restore them in onCreate.
Attachment #8808385 - Flags: review?(s.kaspari)
Comment on attachment 8808385 [details] [diff] [review]
Preserve toolbar color/title through orientation changes

Review of attachment 8808385 [details] [diff] [review]:
-----------------------------------------------------------------

::: mobile/android/base/java/org/mozilla/gecko/customtabs/CustomTabsActivity.java
@@ +5,5 @@
>  
>  package org.mozilla.gecko.customtabs;
>  
> +import android.graphics.drawable.ColorDrawable;
> +

nit: Empty line between android.* imports
Attachment #8808385 - Flags: review?(s.kaspari) → review+
Pushed by droeh@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/0d7eda3bfe63
Handle orientation changes in CustomTabsActivity without losing toolbar color or title. r=sebastian
https://hg.mozilla.org/mozilla-central/rev/0d7eda3bfe63
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 52
Verified as fixed in Build 57.0b9 and 58.0a1.
Devices: Mototola Nexus 6 (Android 7.1.1) and Sony Xperia Z5 Premium (Android 6.0.1).
Rotating a device to landscape/portrait when CustomTab activity is launched doesn't change the toolbar color.
Status: RESOLVED → VERIFIED
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: