зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1409277 - Ignore non-URLs for background pres attr. r=manishearth
Check background attribute values for the same types (URL, image) in Stylo mode as we do in Gecko mode. In particular, this ignores the edge case of the empty attribute, which comes through as a string value type, and leads Stylo to trigger a load of the page itself as the background image (since the empty URL is interpreted as relative to the page). MozReview-Commit-ID: CUhq5nS8kVw --HG-- extra : rebase_source : 8a04a3175cb1a873ee7e597ad881ae64720c01ef
This commit is contained in:
Родитель
3961574fa2
Коммит
8766fcbe53
|
@ -121,6 +121,10 @@ ServoSpecifiedValues::SetTextDecorationColorOverride()
|
|||
void
|
||||
ServoSpecifiedValues::SetBackgroundImage(nsAttrValue& aValue)
|
||||
{
|
||||
if (aValue.Type() != nsAttrValue::eURL &&
|
||||
aValue.Type() != nsAttrValue::eImage) {
|
||||
return;
|
||||
}
|
||||
nsAutoString str;
|
||||
aValue.ToString(str);
|
||||
Servo_DeclarationBlock_SetBackgroundImage(
|
||||
|
|
Загрузка…
Ссылка в новой задаче