[webkit-qt] How to save data from webkit requests

Richard Baron Penman richardbp at gmail.com
Wed Oct 6 22:51:36 PDT 2010


figured it out - the docs are wrong. readData() only takes an int and
returns a string:

def readData(self, size):
>         size = min(size, len(self.buffer))
>         data, self.buffer = self.buffer[:size], self.buffer[size:]
>         return str(data)
>

Thanks for tips and advice Ben,
Richard


On Wed, Oct 6, 2010 at 2:39 PM, Richard Baron Penman <richardbp at gmail.com>wrote:

> On Wed, Oct 6, 2010 at 12:13 AM, Benjamin Poulain <
> benjamin.poulain at nokia.com> wrote:
>
>> On 10/05/2010 02:00 PM, ext Richard Baron Penman wrote:
>>
>>> this is what I currently have: http://pastebin.com/Ugt0EC40
>>>
>>> I find that the html at the URL is downloaded correctly and then the
>>> finished() signal is emitted, but the content of QWebView remains empty.
>>> How does QWebView get the content from QNetworkReply? Neither peek(),
>>> read(), readLine(), readData(), or readAll() is ever called in this
>>> class, but it will render properly when I use a standard QNetworkReply.
>>>
>>
>> I am not familiar with the python bindings. If readData is never called, a
>> signal is probably never emitted.
>>
>> Look at
>> http://gitorious.org/webkit/webkit/blobs/master/WebCore/platform/network/qt/QNetworkReplyHandler.cpp#line550to see what signals are used by WebKit.
>>
>
>
> yeah I looked over the source but didn't figure it out, so I was asking for
> alternatives.
> Any ideas?
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-qt/attachments/20101007/95f3e25e/attachment.html>


More information about the webkit-qt mailing list