Closed Bug 840346 Opened 7 years ago Closed 7 years ago

[Holo] Flat UI

Categories

(Firefox for Android :: Theme and Visual Design, defect)

ARM
Android
defect
Not set

Tracking

()

RESOLVED FIXED
Firefox 21
Tracking Status
relnote-firefox --- 21+

People

(Reporter: sriram, Unassigned)

Details

Attachments

(6 files, 1 obsolete file)

Remove all textures, use solid colors for all the backgrounds.
This removes a whole bunch of stuff in Java, replaces few resources for the rounded rectangle. Only colors are used everywhere.
Attachment #712719 - Flags: review?(mark.finkle)
Attached patch Part 2: Proper persona methods (obsolete) — Splinter Review
Ideally its better to combine both the colors into and paint it (earlier one was a texture and the other a color). But I couldn't find a proper filter. So, this just replaces texture with a color.

And few renaming for my OCD. :D
Attachment #712721 - Flags: review?(mark.finkle)
These sync icons were there for no reason. Purged completely.
Attachment #712722 - Flags: review?(mark.finkle)
And flat UI for about:pages. This removes the images and replaces them with colors.
Attachment #712723 - Flags: review?(mark.finkle)
Adding kats to remove the "abouthome_bg" texture used by LayerView, and replaced it with R.color.background_normal.
This fixes the color-filter problem with persona. Now that we are using solid colors (yaay!), we can combine the solid color (like the grey), with a dominant color using a color filter. This when drawn, it's drawn as one single paint operation rather than two. That's a win!

May be, if we find the color filter to be slower, we can combine the two colors ourselves and set it as a single color to paint. But I don't think color filter is slower. Android does it for us for free :D

Also, I find the about:home to scroll a bit faster with personas -- with this change.
Attachment #712721 - Attachment is obsolete: true
Attachment #712721 - Flags: review?(mark.finkle)
Attachment #713020 - Flags: review?(mark.finkle)
Comment on attachment 712719 [details] [diff] [review]
Part 1: Flat URL bar

I can't wait to see this in the app. The code cleanup alone is really nice. You might want to double check you removed all the files we no longer need.
Attachment #712719 - Flags: review?(mark.finkle) → review+
Comment on attachment 712722 [details] [diff] [review]
Part 3: Unwanted icons

Yay! for more cleanup
Attachment #712722 - Flags: review?(mark.finkle) → review+
Comment on attachment 712723 [details] [diff] [review]
Part 4: Flat about: pages

I am slightly worried that add-ons might be using these background images. We can see if anyone reports problems with add-on about: pages.
Attachment #712723 - Flags: review?(mark.finkle) → review+
Attachment #713020 - Flags: review?(mark.finkle) → review+
Here's a patch that gets rid of the background layer and replaces it with a solid Color.MAGENTA. You can replace that color with whatever you like, or pull it from a resource file or whatever. I'm leaving it without a review request for now since I don't know if you want to make more changes on this, but if you want it reviewed Cwiiis would probably be the best reviewer for this patch.
Comment on attachment 713606 [details] [diff] [review]
Part x: Get rid of the background tile layer

I would like to replace Color.MAGENTA with a | mView.getContext().getResources().getColor(R.color.background_normal) | before pushing.
Attachment #713606 - Flags: review?(chrislord.net)
Whiteboard: [leave open]
Comment on attachment 713606 [details] [diff] [review]
Part x: Get rid of the background tile layer

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

LGTM, assuming the colour will be changed.

::: mobile/android/base/gfx/LayerRenderer.java
@@ +536,5 @@
>  
> +            // Clear the page area to the page background colour.
> +            setScissorRect();
> +            clear(mBackgroundColor);
> +            GLES20.glDisable(GLES20.GL_SCISSOR_TEST);

I'd be interested to know if a clear+scissor is faster or slower than a texture draw... Are there any talos results? Specifically, tpan.
Attachment #713606 - Flags: review?(chrislord.net) → review+
Zarro textures found!
Attachment #713972 - Flags: review?(mark.finkle)
Attachment #713972 - Flags: review?(mark.finkle) → review+
https://hg.mozilla.org/mozilla-central/rev/a119a9b9d390
https://hg.mozilla.org/mozilla-central/rev/e36402a56225
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 21
You need to log in before you can comment on or make changes to this bug.