[Webkit-unassigned] [Bug 29710] [Qt] QtWebKit does not support QGraphicsWidget-plugins

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


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


Simon Hausmann <hausmann at webkit.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #40295|review?(hausmann at webkit.org |review-
               Flag|)                           |




--- Comment #6 from Simon Hausmann <hausmann at webkit.org>  2009-10-02 07:35:15 PDT ---
(From update of attachment 40295)
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.

-- 
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