[webkit-reviews] review denied: [Bug 29710] [Qt] QtWebKit does not support QGraphicsWidget-plugins : [Attachment 40295] Revised patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Oct 2 07:35:14 PDT 2009


Simon Hausmann <hausmann at webkit.org> has denied J-P Nurmi <jpnurmi at gmail.com>'s
request for review:
Bug 29710: [Qt] QtWebKit does not support QGraphicsWidget-plugins
https://bugs.webkit.org/show_bug.cgi?id=29710

Attachment 40295: Revised patch
https://bugs.webkit.org/attachment.cgi?id=40295&action=review

------- Additional Comments from Simon Hausmann <hausmann at webkit.org>
Hi J-P,

sorry for the long delay :-(

I think your patch is good, I like the way that it's not neccessary for
subclasses to provide a parent item. However
I think the approach of storing a pointer to the QGraphicsWidget is a bit
fragile. I would prefer of we could extend
QWebPageClient with a virtual function that returns a QObject that is to be
used as parent for plugins. In the implementation 
it would look like this:

class QWebPageClient {
    ...
    QObject* pluginParent() const = 0;
    ...
}

and then

QObject* QWebViewPrivate::pluginParent() const
{
    return q_func();
}

QObject* QGraphicsWebViewPrivate::pluginParent() const
{
    return q_func();
}

> +		  
graphicsWidget->setParentItem(m_webFrame->page()->d->graphicsWidget);

... and then the above becomes:

graphicsWidget->setParentItem(qobject_cast<QGraphicsObject*>(m_webFrame->page()
->d->client->pluginParent()

And the same for the QWidget based plugins.


More information about the webkit-reviews mailing list