What if a html page uses a iframe for images?

Koos Vriezen koos.vriezen at xs4all.nl
Mon Aug 30 19:43:19 BST 2004


On Sat, Aug 21, 2004 at 09:46:59PM +0200, Koos Vriezen wrote:
> On Sat, Aug 14, 2004 at 10:39:28PM +0200, Koos Vriezen wrote:
> > I think that KJS::WindowObject still needs fixing.
> KJS::WindowQObject that is. Anyway, attached a fix for it. First I
> thought that creating a WindowQObject for a KHTMLPart, like it is now,
> would be enought. Looking closer, I see that KJSWindow::clear can't know
> if the new KParts::ReadOnlyPart will be a KHTMLPart or not. So again use
> a khtml::ChildFrame (actually it's only used for the QObject::destructed
> signal, so can't hurt I think).
> There is a change in the detection of the existance of jscript. It was
>   KJSProxy* proxy = part->jScript();
> and I changed it to
>   KJSProxy* proxy = m_frame->m_jscript;
> First case can create a new one and the second not. But I can't think of
> an case that the KJS::Window does exist and this
> khtml::ChildFrame::m_jscript field is NULL (other than explicit
> disabling of javascript, but then the next test will fail like it
> should). David, can you confirm this?

Oh well, I just commit this then in a few days with small change (see
below)

> Index: ecma/kjs_window.h
> -    KHTMLPart *part;   		// not guarded, may be dangling
> +    khtml::ChildFrame *frame;   	// not guarded, may be dangling

as frame only is used to put a slot on frame's destruction signal in
KJS::WindowQObject constructor, we might as well remove it here.

Koos




More information about the kfm-devel mailing list