diff --git a/widgets/webcontent.cpp b/widgets/webcontent.cpp index 430cea837..dfd048820 100644 --- a/widgets/webcontent.cpp +++ b/widgets/webcontent.cpp @@ -70,13 +70,13 @@ void WebContent::setHtml(const QByteArray &html, const QUrl &baseUrl) } } -QSizeF WebContent::geometry() const +QRectF WebContent::geometry() const { if (d->loaded && d->page) { - return d->page->mainFrame()->contentsSize(); + return d->page->mainFrame()->geometry(); } - return QGraphicsWidget::geometry().size(); + return QGraphicsWidget::geometry(); } void WebContent::setPage(QWebPage *page) diff --git a/widgets/webcontent.h b/widgets/webcontent.h index 6d39ec121..b2250b579 100644 --- a/widgets/webcontent.h +++ b/widgets/webcontent.h @@ -59,7 +59,7 @@ class PLASMA_EXPORT WebContent : public QGraphicsWidget /** * Reimplementation */ - QSizeF geometry() const; + QRectF geometry() const; /** * Sets the page to use in this item. The owner of the webpage remains,