AW: AW: bugfix KHTMLPart::started(KIO::Job *job)

Tobias Anton TA at ESC-Electronics.de
Thu Sep 23 13:10:38 BST 2004


On Dienstag, 2. September 2003 11:17, Grimm, Cornelius wrote:
> Hi,
>
> > > Now, if "slotLoaderRequestDone()" get's called _before_ the document
> > > exists, checkComplete does the completion stuff. And the document is
> > > created in begin(), which is called when the first piece of
> >
> > data arrives.
> >
> > > This might happen later than the call of "slotLoaderRequestDone()".
> >
> > Do you use a user stylesheet? Otherwise I cannot imagine why
> > slotLoaderRequestDone would be called before the document
> > exists, but it
> > would be interesting to find out why and then fix it.
>
> I found out why.
>
> In the init() function of KHTMLPart we connect to the requestDone() signal
> of the global loader object returned by khtml::Cache::loader().
>
> So the slot slotLoaderRequestDone() of KHTMLPart gets called whenever any
> other request is complete, even in completely different KHTMLPart windows
> within this application.
>
> The implementation of slotLoaderRequestDone() should only call
> checkCompleted() if the khtml::DocLoader belongs to this KHTMLPart, but I
> don't know how to check this (because the document which knows about it's
> loader might be non-existent when the request failed, or not?).

Every dom document has an own docloader accessible from KHTMLPart via 
d->m_doc->docLoader().

Cheers
-- Tobias




More information about the kfm-devel mailing list