mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-03 14:28:39 +09:00
Improve origin-clean algorithm
This commit is contained in:
parent
21eef2bff9
commit
85e68b684f
5 changed files with 41 additions and 39 deletions
|
|
@ -8,6 +8,7 @@
|
|||
|
||||
#include "mozilla/ArrayUtils.h"
|
||||
#include "mozilla/BasicEvents.h"
|
||||
#include "mozilla/dom/CanvasUtils.h"
|
||||
#include "mozilla/ClearOnShutdown.h"
|
||||
#include "mozilla/EffectCompositor.h"
|
||||
#include "mozilla/EffectSet.h"
|
||||
|
|
@ -7285,10 +7286,10 @@ nsLayoutUtils::SurfaceFromElement(nsIImageLoadingContent* aElement,
|
|||
}
|
||||
|
||||
result.mPrincipal = principal.forget();
|
||||
// no images, including SVG images, can load content from another domain.
|
||||
result.mIsWriteOnly = false;
|
||||
result.mImageRequest = imgRequest.forget();
|
||||
return result;
|
||||
result.mIsWriteOnly =
|
||||
CanvasUtils::CheckWriteOnlySecurity(result.mCORSUsed, result.mPrincipal);
|
||||
}
|
||||
|
||||
nsLayoutUtils::SurfaceFromElementResult
|
||||
|
|
@ -7400,7 +7401,8 @@ nsLayoutUtils::SurfaceFromElement(HTMLVideoElement* aElement,
|
|||
result.mHasSize = true;
|
||||
result.mSize = result.mLayersImage->GetSize();
|
||||
result.mPrincipal = principal.forget();
|
||||
result.mIsWriteOnly = false;
|
||||
result.mIsWriteOnly =
|
||||
CanvasUtils::CheckWriteOnlySecurity(result.mCORSUsed, result.mPrincipal);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue