Closed Bug 855911 Opened 12 years ago Closed 11 years ago

Handle favicon creation and scaling in browser.js, not in Java

Categories

(Firefox for Android Graveyard :: General, defect)

All
Android
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: wesj, Assigned: ckitching)

References

Details

Attachments

(1 file, 1 obsolete file)

Nvidia is sending us an ico file. Java grabs the last icon in the file (I think). We have no control over this AFAIK, but in Gecko we do. It might be better if we could do all our favicon resizing in Gecko regardless, where we have more control over the resample algorithms.
Attached patch WIP Patch (obsolete) — Splinter Review
I want to clean this up and play with it a bit more, but getting there.
Attached patch PatchSplinter Review
This moves our favicon creation and scaling to browser.js (we're caching these in Favicons.java, so for the most part any speed hit should be small?). It sends pass a data-uri with the favicon to Java now. If there is no icon, java would previously attempt to use favicon.ico. This has the Java frontend send a message to Gecko requesting the favicon.ico icon be loaded instead. I also duplicated our scaling code here. If the icon is the same size or more than a minimum, we scale it up, otherwise we scale down. The big benefit here though is just that we can pick better icons from ico images than we could with Android's bitmap decoder.
Attachment #730985 - Attachment is obsolete: true
Attachment #731277 - Flags: review?(mark.finkle)
Blocks: 507641
Assignee: nobody → ckitching
Depends on: ICODecoder
Blocks: 895423
Status: NEW → ASSIGNED
Attachment #731277 - Flags: review?(mark.finkle)
Fixed by Bug 748100.
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
That hasn't landed yet, has it?
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
(In reply to Ryan VanderMeulen [:RyanVM UTC-4] from comment #6) > That hasn't landed yet, has it? Correct. This is fixed by the ICODecoder which is yet to land. Feel free to steal that bug, anyone who is bored and has this mythical "Free time".
I think the correct resolution for this is "WONTFIX in favor of…" -- we can reopen it later if there's some pressing need to do the work in Gecko, but in the mean time the landed-and-forthcoming Java stuff will solve the issue.
Status: REOPENED → RESOLVED
Closed: 11 years ago11 years ago
OS: Linux → Android
Hardware: x86 → All
Resolution: --- → WONTFIX
Summary: nvidia.com favicon is ugly → Handle favicon creation and scaling in browser.js, not in Java
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: