[Webkit-unassigned] [Bug 119654] [Qt] Avoid calling QWebPage's virtual functions during deletion of QWebPage

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Aug 12 03:16:29 PDT 2013


https://bugs.webkit.org/show_bug.cgi?id=119654





--- Comment #7 from Allan Sandfeld Jensen <allan.jensen at digia.com>  2013-08-12 03:16:05 PST ---
(In reply to comment #6)
> (In reply to comment #5)
> > (In reply to comment #4)
> > > (In reply to comment #3)
> > > > (In reply to comment #2)
> > > > > Since QWebPage is already a wrapper around QWebPageAdaptor why can't you call QWebPageAdaptor::preparetoDestroy() from the qwebpage destructor?
> > > > 
> > > > When control reaches ~QWebPage derived class already been destroyed(~UnLoadTestPage).
> > > 
> > > True, but that only matters if you need the overloaded alert like the test-case. Most common cases of what happens on unload would work, wouldn't it?
> > 
> > Nevermind that was the entire case of the bug-report. 
> > 
> > If this depends on the user of qwebpage calling an extra method, could he call something to unload the page instead? 
> > 
> > Perhaps mainFram()->setHtml("") ?
> 
> Thanks Allan, I tried this, it is not working. Might be because of its async. nature of mainFrame()->setHtml() I guess :(

Another option might be to only introduce the close or unload method on qwebpage level and call QWebPageAdapter::deletePage(). I think it will do the same, but using the iterative detach/closeURL in FrameLoader.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list