[Webkit-unassigned] [Bug 120168] Fix srcset's image candidate algorithm when DPR exceeds all candidates

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Aug 22 13:17:58 PDT 2013


https://bugs.webkit.org/show_bug.cgi?id=120168





--- Comment #2 from Yoav Weiss <yoav at yoav.ws>  2013-08-22 13:17:26 PST ---
When the DPR exceeded the 'x' qualifier of all image candidates, none was chosen.

According to the srcset spec: "If there are any entries in candidates that have an associated pixel density that is less than a user-agent-defined value giving the nominal pixel density of the display, then remove them, unless that would remove all the entries, in which case remove only the entries whose associated pixel density is less than the greatest such pixel density."

Fixed by returning the last candidate in the list of candidates sorted by their qualifier, in case none of them is equal or greater than the DPR.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list