| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2004, 2006, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2004, 2006, 2008 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2005-2007 Alexey Proskuryakov <ap@webkit.org> | 3 * Copyright (C) 2005-2007 Alexey Proskuryakov <ap@webkit.org> |
| 4 * Copyright (C) 2007, 2008 Julien Chaffraix <jchaffraix@webkit.org> | 4 * Copyright (C) 2007, 2008 Julien Chaffraix <jchaffraix@webkit.org> |
| 5 * Copyright (C) 2008, 2011 Google Inc. All rights reserved. | 5 * Copyright (C) 2008, 2011 Google Inc. All rights reserved. |
| 6 * Copyright (C) 2012 Intel Corporation | 6 * Copyright (C) 2012 Intel Corporation |
| 7 * | 7 * |
| 8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
| 9 * modify it under the terms of the GNU Lesser General Public | 9 * modify it under the terms of the GNU Lesser General Public |
| 10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
| (...skipping 771 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 782 if (areMethodAndURLValidForSend()) { | 782 if (areMethodAndURLValidForSend()) { |
| 783 if (getRequestHeader("Content-Type").isEmpty()) { | 783 if (getRequestHeader("Content-Type").isEmpty()) { |
| 784 // FIXME: this should include the charset used for encoding. | 784 // FIXME: this should include the charset used for encoding. |
| 785 setRequestHeaderInternal("Content-Type", "application/xml"); | 785 setRequestHeaderInternal("Content-Type", "application/xml"); |
| 786 } | 786 } |
| 787 | 787 |
| 788 // FIXME: According to XMLHttpRequest Level 2, this should use the Docum
ent.innerHTML algorithm | 788 // FIXME: According to XMLHttpRequest Level 2, this should use the Docum
ent.innerHTML algorithm |
| 789 // from the HTML5 specification to serialize the document. | 789 // from the HTML5 specification to serialize the document. |
| 790 String body = createMarkup(document); | 790 String body = createMarkup(document); |
| 791 | 791 |
| 792 // FIXME: This should use value of document.inputEncoding to determine t
he encoding to use. | |
| 793 httpBody = FormData::create(UTF8Encoding().encode(body, WTF::EntitiesFor
Unencodables)); | 792 httpBody = FormData::create(UTF8Encoding().encode(body, WTF::EntitiesFor
Unencodables)); |
| 794 } | 793 } |
| 795 | 794 |
| 796 createRequest(httpBody.release(), exceptionState); | 795 createRequest(httpBody.release(), exceptionState); |
| 797 } | 796 } |
| 798 | 797 |
| 799 void XMLHttpRequest::send(const String& body, ExceptionState& exceptionState) | 798 void XMLHttpRequest::send(const String& body, ExceptionState& exceptionState) |
| 800 { | 799 { |
| 801 WTF_LOG(Network, "XMLHttpRequest %p send() String '%s'", this, body.utf8().d
ata()); | 800 WTF_LOG(Network, "XMLHttpRequest %p send() String '%s'", this, body.utf8().d
ata()); |
| 802 | 801 |
| (...skipping 979 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1782 visitor->trace(m_responseDocument); | 1781 visitor->trace(m_responseDocument); |
| 1783 visitor->trace(m_responseDocumentParser); | 1782 visitor->trace(m_responseDocumentParser); |
| 1784 visitor->trace(m_progressEventThrottle); | 1783 visitor->trace(m_progressEventThrottle); |
| 1785 visitor->trace(m_upload); | 1784 visitor->trace(m_upload); |
| 1786 visitor->trace(m_blobLoader); | 1785 visitor->trace(m_blobLoader); |
| 1787 XMLHttpRequestEventTarget::trace(visitor); | 1786 XMLHttpRequestEventTarget::trace(visitor); |
| 1788 DocumentParserClient::trace(visitor); | 1787 DocumentParserClient::trace(visitor); |
| 1789 } | 1788 } |
| 1790 | 1789 |
| 1791 } // namespace blink | 1790 } // namespace blink |
| OLD | NEW |