зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1333058 - Get rid of MultipartBlobImpl::InitializeChromeFile, r=qdot
This commit is contained in:
Родитель
f7dda0c14d
Коммит
c2381922c7
|
@ -323,38 +323,6 @@ MultipartBlobImpl::SetMutable(bool aMutable)
|
||||||
return NS_OK;
|
return NS_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
MultipartBlobImpl::InitializeChromeFile(Blob& aBlob,
|
|
||||||
const ChromeFilePropertyBag& aBag,
|
|
||||||
ErrorResult& aRv)
|
|
||||||
{
|
|
||||||
MOZ_ASSERT(!mImmutable, "Something went wrong ...");
|
|
||||||
|
|
||||||
if (mImmutable) {
|
|
||||||
aRv.Throw(NS_ERROR_UNEXPECTED);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
MOZ_ASSERT(nsContentUtils::ThreadsafeIsCallerChrome());
|
|
||||||
|
|
||||||
mName = aBag.mName;
|
|
||||||
mContentType = aBag.mType;
|
|
||||||
mIsFromNsIFile = true;
|
|
||||||
|
|
||||||
// XXXkhuey this is terrible
|
|
||||||
if (mContentType.IsEmpty()) {
|
|
||||||
aBlob.GetType(mContentType);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
BlobSet blobSet;
|
|
||||||
blobSet.AppendBlobImpl(aBlob.Impl());
|
|
||||||
mBlobImpls = blobSet.GetBlobImpls();
|
|
||||||
|
|
||||||
SetLengthAndModifiedDate(aRv);
|
|
||||||
NS_WARNING_ASSERTION(!aRv.Failed(), "SetLengthAndModifiedDate failed");
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
void
|
||||||
MultipartBlobImpl::InitializeChromeFile(nsPIDOMWindowInner* aWindow,
|
MultipartBlobImpl::InitializeChromeFile(nsPIDOMWindowInner* aWindow,
|
||||||
nsIFile* aFile,
|
nsIFile* aFile,
|
||||||
|
|
|
@ -60,10 +60,6 @@ public:
|
||||||
bool aNativeEOL,
|
bool aNativeEOL,
|
||||||
ErrorResult& aRv);
|
ErrorResult& aRv);
|
||||||
|
|
||||||
void InitializeChromeFile(Blob& aData,
|
|
||||||
const ChromeFilePropertyBag& aBag,
|
|
||||||
ErrorResult& aRv);
|
|
||||||
|
|
||||||
void InitializeChromeFile(nsPIDOMWindowInner* aWindow,
|
void InitializeChromeFile(nsPIDOMWindowInner* aWindow,
|
||||||
const nsAString& aData,
|
const nsAString& aData,
|
||||||
const ChromeFilePropertyBag& aBag,
|
const ChromeFilePropertyBag& aBag,
|
||||||
|
|
Загрузка…
Ссылка в новой задаче