зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1431774 part 3. de-COM the image loading content loadingEnabled API. r=mystor
MozReview-Commit-ID: 3JpN3ZZVNg3
This commit is contained in:
Родитель
bd29cf763a
Коммит
985bac7189
|
@ -59,11 +59,11 @@ interface nsIImageLoadingContent : imgINotificationObserver
|
|||
const long PENDING_REQUEST = 1;
|
||||
|
||||
/**
|
||||
* loadingEnabled is used to enable and disable loading in
|
||||
* setLoadingEnabled is used to enable and disable loading in
|
||||
* situations where loading images is unwanted. Note that enabling
|
||||
* loading will *not* automatically trigger an image load.
|
||||
*/
|
||||
[noscript] attribute boolean loadingEnabled;
|
||||
[notxpcom, nostdcall] void setLoadingEnabled(in boolean aEnabled);
|
||||
|
||||
/**
|
||||
* Returns the image blocking status (@see nsIContentPolicy). This
|
||||
|
|
|
@ -331,20 +331,12 @@ nsImageLoadingContent::OnImageIsAnimated(imgIRequest *aRequest)
|
|||
* nsIImageLoadingContent impl
|
||||
*/
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsImageLoadingContent::GetLoadingEnabled(bool *aLoadingEnabled)
|
||||
{
|
||||
*aLoadingEnabled = mLoadingEnabled;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
void
|
||||
nsImageLoadingContent::SetLoadingEnabled(bool aLoadingEnabled)
|
||||
{
|
||||
if (nsContentUtils::GetImgLoaderForChannel(nullptr, nullptr)) {
|
||||
mLoadingEnabled = aLoadingEnabled;
|
||||
}
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
|
|
Загрузка…
Ссылка в новой задаче