Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7)

Unified Diff: WebCore/xml/XMLHttpRequest.cpp

Issue 5569001: Merge 72866 - Add send(ArrayBuffer) to XMLHttpRequest per XMLHttpRequest Leve... (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/597/
Patch Set: Created 10 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « WebCore/xml/XMLHttpRequest.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: WebCore/xml/XMLHttpRequest.cpp
===================================================================
--- WebCore/xml/XMLHttpRequest.cpp (revision 73109)
+++ WebCore/xml/XMLHttpRequest.cpp (working copy)
@@ -586,6 +586,22 @@
createRequest(ec);
}
+#if ENABLE(3D_CANVAS) || ENABLE(BLOB)
+void XMLHttpRequest::send(ArrayBuffer* body, ExceptionCode& ec)
+{
+ if (!initSend(ec))
+ return;
+
+ if (m_method != "GET" && m_method != "HEAD" && m_url.protocolInHTTPFamily()) {
+ m_requestEntityBody = FormData::create(body->data(), body->byteLength());
+ if (m_upload)
+ m_requestEntityBody->setAlwaysStream(true);
+ }
+
+ createRequest(ec);
+}
+#endif
+
void XMLHttpRequest::createRequest(ExceptionCode& ec)
{
#if ENABLE(BLOB)
« no previous file with comments | « WebCore/xml/XMLHttpRequest.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698