Bug 1301245 - Part 1. Implement nsStyleImage::IsResolved. r=heycam

We need this new API in the following patch.

MozReview-Commit-ID: JSoCgzKWrfs

--HG--
extra : rebase_source : e7da0a990b991b1c417015a9cb4f9e2b1e98faae
extra : source : 8f02c1ea8448315f9284939823d66e67cdc5ad87
This commit is contained in:
cku 2017-07-20 01:02:17 +08:00
Родитель d55ba2551d
Коммит d869a580cc
1 изменённых файлов: 3 добавлений и 0 удалений

Просмотреть файл

@ -463,6 +463,9 @@ struct nsStyleImage
NS_ASSERTION(mType == eStyleImageType_Gradient, "Data is not a gradient!");
return mGradient;
}
bool IsResolved() const {
return mType != eStyleImageType_Image || GetImageRequest()->IsResolved();
}
const nsIAtom* GetElementId() const {
NS_ASSERTION(mType == eStyleImageType_Element, "Data is not an element!");
return mElementId;