Changeset 25796 in webkit
- Timestamp:
- Sep 28, 2007 11:31:55 AM (17 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebCore/ChangeLog
r25795 r25796 1 2007-09-27 Kevin McCullough <kmccullough@apple.com> 2 3 Reviewed by Darin. 4 5 - <rdar://5261371> Nothing downloaded when exporting bookmarks from iGoogle web history 6 - Implemented IWebHTTPURLResponse::allHeaderFields so that if the content disposition is "attachment" we will download the file instead of display it. Also implemented some missing functionality. 7 8 * platform/network/ResourceResponse.cpp: 9 (WebCore::ResourceResponse::isAttachment): 10 * platform/network/ResourceResponse.h: 11 1 12 2007-09-27 Mitz Pettel <mitz@webkit.org> 2 13 -
trunk/WebCore/platform/network/ResourceResponse.cpp
r24372 r25796 164 164 } 165 165 166 bool ResourceResponse::isAttachment() const 167 { 168 updateResourceResponse(); 169 170 String value = m_httpHeaderFields.get("Content-Disposition"); 171 int loc = value.find(';'); 172 if (loc != -1) 173 value = value.left(loc); 174 value = value.stripWhiteSpace(); 175 return equalIgnoringCase(value, "attachment"); 176 } 177 166 178 void ResourceResponse::setExpirationDate(time_t expirationDate) 167 179 { -
trunk/WebCore/platform/network/ResourceResponse.h
r24372 r25796 101 101 bool isMultipart() const { return mimeType() == "multipart/x-mixed-replace"; } 102 102 103 bool isAttachment() const; 104 103 105 void setExpirationDate(time_t); 104 106 time_t expirationDate() const; -
trunk/WebKit/win/ChangeLog
r25784 r25796 1 2007-09-27 Kevin McCullough <kmccullough@apple.com> 2 3 Reviewed by Darin. 4 5 - <rdar://5261371> Nothing downloaded when exporting bookmarks from iGoogle web history 6 - Implemented IWebHTTPURLResponse::allHeaderFields so that if the content disposition is "attachment" we will download the file instead of display it. Also implemented some missing functionality. 7 8 * HTTPHeaderPropertyBag.cpp: Added. 9 (HTTPHeaderPropertyBag::HTTPHeaderPropertyBag): 10 (HTTPHeaderPropertyBag::createInstance): 11 (HTTPHeaderPropertyBag::setResponse): 12 (HTTPHeaderPropertyBag::response): 13 (HTTPHeaderPropertyBag::QueryInterface): 14 (HTTPHeaderPropertyBag::AddRef): 15 (HTTPHeaderPropertyBag::Release): 16 (ConvertFromLPCOLESTR): 17 (ConvertToVariant): 18 (ConvertFromVariant): 19 (HTTPHeaderPropertyBag::Read): 20 (HTTPHeaderPropertyBag::Write): 21 * HTTPHeaderPropertyBag.h: Added. 22 * Interfaces/IWebHTTPURLResponse.idl: 23 * WebKit.vcproj/WebKit.vcproj: 24 * WebURLResponse.cpp: 25 (WebURLResponse::allHeaderFields): 26 (WebURLResponse::isAttachment): 27 * WebURLResponse.h: 28 1 29 2007-09-27 Ada Chan <adachan@apple.com> 2 30 -
trunk/WebKit/win/Interfaces/IWebHTTPURLResponse.idl
r23357 r25796 64 64 HRESULT localizedStringForStatusCode([in] int statusCode, [out, retval] BSTR* statusString); 65 65 HRESULT statusCode([out, retval] int* statusCode); 66 HRESULT isAttachment([out, retval] BOOL* attachment); 66 67 } -
trunk/WebKit/win/WebKit.vcproj/WebKit.vcproj
r25530 r25796 367 367 </File> 368 368 <File 369 RelativePath="..\HTTPHeaderPropertyBag.h" 370 > 371 </File> 372 <File 369 373 RelativePath="..\MarshallingHelpers.h" 370 374 > … … 584 588 <File 585 589 RelativePath="..\DOMHTMLClasses.cpp" 590 > 591 </File> 592 <File 593 RelativePath="..\HTTPHeaderPropertyBag.cpp" 586 594 > 587 595 </File> -
trunk/WebKit/win/WebURLResponse.cpp
r25272 r25796 29 29 #include "WebURLResponse.h" 30 30 31 #include "HTTPHeaderPropertyBag.h" 31 32 #include "MarshallingHelpers.h" 32 33 #include "WebLocalizableStrings.h" … … 357 358 { 358 359 ASSERT(m_response.isHTTP()); 359 if (headerFields) 360 *headerFields = 0; 361 return E_NOTIMPL; 360 *headerFields = HTTPHeaderPropertyBag::createInstance(this); 361 return S_OK; 362 362 } 363 363 … … 385 385 return S_OK; 386 386 } 387 388 HRESULT STDMETHODCALLTYPE WebURLResponse::isAttachment( 389 /* [retval][out] */ BOOL *attachment) 390 { 391 *attachment = m_response.isAttachment(); 392 return S_OK; 393 } 394 387 395 388 396 HRESULT STDMETHODCALLTYPE WebURLResponse::sslPeerCertificate( -
trunk/WebKit/win/WebURLResponse.h
r25272 r25796 86 86 /* [retval][out] */ int *statusCode); 87 87 88 virtual HRESULT STDMETHODCALLTYPE isAttachment( 89 /* [retval][out] */ BOOL *attachment); 90 88 91 // IWebURLResponsePrivate 89 92 virtual HRESULT STDMETHODCALLTYPE sslPeerCertificate(
Note: See TracChangeset
for help on using the changeset viewer.