diff options
Diffstat (limited to 'WebCore/platform/chromium/ChromiumDataObject.cpp')
-rw-r--r-- | WebCore/platform/chromium/ChromiumDataObject.cpp | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/WebCore/platform/chromium/ChromiumDataObject.cpp b/WebCore/platform/chromium/ChromiumDataObject.cpp index 77a5f0f..5c67c65 100644 --- a/WebCore/platform/chromium/ChromiumDataObject.cpp +++ b/WebCore/platform/chromium/ChromiumDataObject.cpp @@ -35,11 +35,17 @@ namespace WebCore { void ChromiumDataObject::clear() { + clearAllExceptFiles(); + filenames.clear(); +} + +void ChromiumDataObject::clearAllExceptFiles() +{ url = KURL(); urlTitle = ""; + uriList.clear(); downloadMetadata = ""; fileExtension = ""; - filenames.clear(); plainText = ""; textHtml = ""; htmlBaseUrl = KURL(); @@ -51,6 +57,7 @@ void ChromiumDataObject::clear() bool ChromiumDataObject::hasData() const { return !url.isEmpty() + || !uriList.isEmpty() || !downloadMetadata.isEmpty() || !fileExtension.isEmpty() || !filenames.isEmpty() @@ -60,8 +67,7 @@ bool ChromiumDataObject::hasData() const } ChromiumDataObject::ChromiumDataObject(const ChromiumDataObject& other) - : url(other.url) - , urlTitle(other.urlTitle) + : urlTitle(other.urlTitle) , downloadMetadata(other.downloadMetadata) , fileExtension(other.fileExtension) , filenames(other.filenames) @@ -69,6 +75,8 @@ ChromiumDataObject::ChromiumDataObject(const ChromiumDataObject& other) , textHtml(other.textHtml) , htmlBaseUrl(other.htmlBaseUrl) , fileContentFilename(other.fileContentFilename) + , url(other.url) + , uriList(other.uriList) { if (other.fileContent.get()) fileContent = other.fileContent->copy(); |