diff options
Diffstat (limited to 'WebKit/qt/Api')
-rw-r--r-- | WebKit/qt/Api/qwebframe.cpp | 12 | ||||
-rw-r--r-- | WebKit/qt/Api/qwebhistory.cpp | 1 | ||||
-rw-r--r-- | WebKit/qt/Api/qwebhistoryinterface.cpp | 2 | ||||
-rw-r--r-- | WebKit/qt/Api/qwebnetworkinterface.cpp | 5 |
4 files changed, 12 insertions, 8 deletions
diff --git a/WebKit/qt/Api/qwebframe.cpp b/WebKit/qt/Api/qwebframe.cpp index 155731c..058a283 100644 --- a/WebKit/qt/Api/qwebframe.cpp +++ b/WebKit/qt/Api/qwebframe.cpp @@ -313,8 +313,10 @@ void QWebFrame::load(const QWebNetworkRequest &req) request.addHTTPHeaderField(val.first, val.second); } - if (!postData.isEmpty()) - request.setHTTPBody(WebCore::FormData::create(postData.constData(), postData.size())); + if (!postData.isEmpty()) { + WTF::RefPtr<WebCore::FormData> formData = new WebCore::FormData(postData.constData(), postData.size()); + request.setHTTPBody(formData); + } d->frame->loader()->load(request); @@ -363,8 +365,10 @@ void QWebFrame::load(const QNetworkRequest &req, request.addHTTPHeaderField(QString::fromLatin1(headerName), QString::fromLatin1(req.rawHeader(headerName))); } - if (!body.isEmpty()) - request.setHTTPBody(WebCore::FormData::create(body.constData(), body.size())); + if (!body.isEmpty()) { + WTF::RefPtr<WebCore::FormData> formData = new WebCore::FormData(body.constData(), body.size()); + request.setHTTPBody(formData); + } d->frame->loader()->load(request); diff --git a/WebKit/qt/Api/qwebhistory.cpp b/WebKit/qt/Api/qwebhistory.cpp index 10127a4..eab7d22 100644 --- a/WebKit/qt/Api/qwebhistory.cpp +++ b/WebKit/qt/Api/qwebhistory.cpp @@ -22,6 +22,7 @@ #include "qwebhistory.h" #include "qwebhistory_p.h" +#include "DeprecatedString.h" #include "PlatformString.h" #include "Image.h" diff --git a/WebKit/qt/Api/qwebhistoryinterface.cpp b/WebKit/qt/Api/qwebhistoryinterface.cpp index 8890350..d3e7efd 100644 --- a/WebKit/qt/Api/qwebhistoryinterface.cpp +++ b/WebKit/qt/Api/qwebhistoryinterface.cpp @@ -23,8 +23,8 @@ #include <QCoreApplication> -#include "PlatformString.h" #include <wtf/Platform.h> +#include "DeprecatedString.h" // FIXME: It's not correct to just implement a WebCore function in WebKit! // This needs to be fixed to match other platforms. diff --git a/WebKit/qt/Api/qwebnetworkinterface.cpp b/WebKit/qt/Api/qwebnetworkinterface.cpp index fd0c694..d68140d 100644 --- a/WebKit/qt/Api/qwebnetworkinterface.cpp +++ b/WebKit/qt/Api/qwebnetworkinterface.cpp @@ -135,9 +135,8 @@ void QWebNetworkRequestPrivate::init(const QString &method, const QUrl &url, con // handle and perform a 'POST' request if (method == "POST") { - Vector<char> data; - resourceRequest->httpBody()->flatten(data); - postData = QByteArray(data.data(), data.size()); + DeprecatedString pd = resourceRequest->httpBody()->flattenToString().deprecatedString(); + postData = QByteArray(pd.ascii(), pd.length()); httpHeader.setValue(QLatin1String("content-length"), QString::number(postData.size())); } } |