Closed Bug 796909 Opened 9 years ago Closed 9 years ago

Use 2x Images on About:Home for HiDPI


(Firefox :: Theme, enhancement)

Not set



Firefox 18


(Reporter: shorlander, Assigned: fryn)




(4 files, 2 obsolete files)

Attached file AboutHome HiDPI Assets - i01 (obsolete) —
Now that bug 781327 has landed we should update about:home to be sharp in HiDPI also.

Attaching the @2x assets. The search engine logo is currently a data URI, I will attach that separate.
Attached patch part 1 (obsolete) — Splinter Review
This was a bit tricky, because we're displaying these images as generated content, but I tackled it with some CSS3. ;)

(Someday, when we merge about:home and about:newtab, we'll pull all the about:home theme code out of browser/base/.)
Assignee: nobody → fryn
Attachment #667141 - Flags: review?(dolske)
Attachment #667228 - Flags: review?(dolske)
Comment on attachment 667228 [details] [diff] [review]
part 2: HiDPI search engine logo

Review of attachment 667228 [details] [diff] [review]:

::: browser/base/content/abouthome/aboutHome.js
@@ +174,5 @@
>      logoElt.src = searchEngineInfo.image;
> +#ifdef XP_MACOSX
> +    if (searchEngineInfo.imageHD && window.matchMedia("(min-resolution: 2dppx)"))
> +      logoElt.src = searchEngineInfo.imageHD;
> +#endif

I suppose, in theory, that putting in an actual CSS @media rule (to control display of a low-res or hi-res image) would be nice for the potential future such that dragging the window from a low-to-high-dpi monitor would be ideal... But I'll take this as a simple patch that we can make better in the future with image-set anyway.
Attachment #667228 - Flags: review?(dolske) → review+
Attachment #667141 - Attachment description: patch → part 1
Attached patch part 1 v2Splinter Review
Added the new default snippet images from "AboutHome HiDPI Assets - i02".
Attachment #667141 - Attachment is obsolete: true
Attachment #667141 - Flags: review?(dolske)
Attachment #667864 - Flags: review?(dolske)
Attachment #667864 - Flags: review?(dolske) → review+

Thanks for the reviews! :)

We'll update the Firefox logo image in a followup bug (which will also allow us to remove about-logo.png from a few directories).
Target Milestone: --- → Firefox 18
You need to log in before you can comment on or make changes to this bug.