Diff
Modified: trunk/Source/WebKit2/ChangeLog (98331 => 98332)
--- trunk/Source/WebKit2/ChangeLog 2011-10-25 09:54:27 UTC (rev 98331)
+++ trunk/Source/WebKit2/ChangeLog 2011-10-25 11:01:51 UTC (rev 98332)
@@ -1,3 +1,37 @@
+2011-10-25 Zalan Bujtas <zbuj...@gmail.com>
+
+ [Qt][WK2] Remove redundant setPageIsVisible() API
+ https://bugs.webkit.org/show_bug.cgi?id=70520
+
+ Use DrawingAreaProxy::visibilityDidChange() instead of DrawingAreaProxy::setPageIsVisible()
+ Remove DrawingAreaProxy::setPageIsVisible(), not used anymore.
+ This change disables the ability of suspending and resuming painting for TiledDrawingAreaProxy.
+ However, TiledDrawingAreaProxy is about to be deprecated by using DrawingAreaProxyImpl
+ as the UI process drawing area proxy for tiled based rendering.
+
+ Reviewed by Simon Hausmann.
+
+ * UIProcess/API/qt/qtouchwebpage.cpp:
+ (QTouchWebPage::QTouchWebPage):
+ (QTouchWebPagePrivate::setPage):
+ * UIProcess/API/qt/qtouchwebpage.h:
+ * UIProcess/API/qt/qtouchwebview.cpp:
+ (QTouchWebView::QTouchWebView):
+ (QTouchWebView::touchEvent):
+ (QTouchWebView::onVisibleChanged):
+ * UIProcess/API/qt/qtouchwebview.h:
+ * UIProcess/DrawingAreaProxy.h:
+ * UIProcess/DrawingAreaProxyImpl.cpp:
+ * UIProcess/DrawingAreaProxyImpl.h:
+ * UIProcess/TiledDrawingAreaProxy.cpp:
+ (WebKit::TiledDrawingAreaProxy::TiledDrawingAreaProxy):
+ (WebKit::TiledDrawingAreaProxy::deviceScaleFactorDidChange):
+ * UIProcess/TiledDrawingAreaProxy.h:
+ * UIProcess/WebPageProxy.cpp:
+ (WebKit::WebPageProxy::viewStateDidChange):
+ * UIProcess/qt/QtWebPageProxy.cpp:
+ * UIProcess/qt/QtWebPageProxy.h:
+
2011-10-25 Carlos Garcia Campos <cgar...@igalia.com>
[GTK] Add go_to_back_forward_list_item() to WebKit2 GTK+ API
Modified: trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebpage.cpp (98331 => 98332)
--- trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebpage.cpp 2011-10-25 09:54:27 UTC (rev 98331)
+++ trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebpage.cpp 2011-10-25 11:01:51 UTC (rev 98332)
@@ -38,7 +38,6 @@
// We do the transform from the top left so the viewport can assume the position 0, 0
// is always where rendering starts.
setTransformOrigin(TopLeft);
- connect(this, SIGNAL(visibleChanged()), SLOT(onVisibleChanged()));
}
QTouchWebPage::~QTouchWebPage()
@@ -161,9 +160,4 @@
this->page = page;
}
-void QTouchWebPage::onVisibleChanged()
-{
- d->page->setPageIsVisible(isVisible());
-}
-
#include "moc_qtouchwebpage.cpp"
Modified: trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebpage.h (98331 => 98332)
--- trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebpage.h 2011-10-25 09:54:27 UTC (rev 98331)
+++ trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebpage.h 2011-10-25 11:01:51 UTC (rev 98332)
@@ -75,9 +75,6 @@
void loadFailed(QTouchWebPage::ErrorType errorType, int errorCode, const QUrl& url);
void loadProgressChanged(int progress);
-protected Q_SLOTS:
- void onVisibleChanged();
-
protected:
virtual void keyPressEvent(QKeyEvent*);
virtual void keyReleaseEvent(QKeyEvent*);
Modified: trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebview.cpp (98331 => 98332)
--- trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebview.cpp 2011-10-25 09:54:27 UTC (rev 98331)
+++ trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebview.cpp 2011-10-25 11:01:51 UTC (rev 98332)
@@ -97,6 +97,7 @@
, d(new QTouchWebViewPrivate(this))
{
setFlags(QSGItem::ItemClipsChildrenToShape);
+ connect(this, SIGNAL(visibleChanged()), SLOT(onVisibleChanged()));
}
QTouchWebView::~QTouchWebView()
@@ -124,4 +125,11 @@
QSGItem::touchEvent(event);
}
+void QTouchWebView::onVisibleChanged()
+{
+ WebPageProxy* pageProxy = toImpl(d->page.pageRef());
+
+ pageProxy->viewStateDidChange(WebPageProxy::ViewIsVisible);
+}
+
#include "moc_qtouchwebview.cpp"
Modified: trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebview.h (98331 => 98332)
--- trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebview.h 2011-10-25 09:54:27 UTC (rev 98331)
+++ trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebview.h 2011-10-25 11:01:51 UTC (rev 98332)
@@ -44,6 +44,9 @@
QTouchWebPage *page();
+protected Q_SLOTS:
+ void onVisibleChanged();
+
protected:
virtual void geometryChanged(const QRectF&, const QRectF&);
virtual void touchEvent(QTouchEvent* event);
Modified: trunk/Source/WebKit2/UIProcess/DrawingAreaProxy.h (98331 => 98332)
--- trunk/Source/WebKit2/UIProcess/DrawingAreaProxy.h 2011-10-25 09:54:27 UTC (rev 98331)
+++ trunk/Source/WebKit2/UIProcess/DrawingAreaProxy.h 2011-10-25 11:01:51 UTC (rev 98332)
@@ -77,8 +77,6 @@
virtual void waitForBackingStoreUpdateOnNextPaint() { }
- virtual void setPageIsVisible(bool isVisible) = 0;
-
const WebCore::IntSize& size() const { return m_size; }
void setSize(const WebCore::IntSize&, const WebCore::IntSize& scrollOffset);
Modified: trunk/Source/WebKit2/UIProcess/DrawingAreaProxyImpl.cpp (98331 => 98332)
--- trunk/Source/WebKit2/UIProcess/DrawingAreaProxyImpl.cpp 2011-10-25 09:54:27 UTC (rev 98331)
+++ trunk/Source/WebKit2/UIProcess/DrawingAreaProxyImpl.cpp 2011-10-25 11:01:51 UTC (rev 98332)
@@ -139,10 +139,6 @@
#endif
}
-void DrawingAreaProxyImpl::setPageIsVisible(bool)
-{
-}
-
void DrawingAreaProxyImpl::setBackingStoreIsDiscardable(bool isBackingStoreDiscardable)
{
if (m_isBackingStoreDiscardable == isBackingStoreDiscardable)
Modified: trunk/Source/WebKit2/UIProcess/DrawingAreaProxyImpl.h (98331 => 98332)
--- trunk/Source/WebKit2/UIProcess/DrawingAreaProxyImpl.h 2011-10-25 09:54:27 UTC (rev 98331)
+++ trunk/Source/WebKit2/UIProcess/DrawingAreaProxyImpl.h 2011-10-25 11:01:51 UTC (rev 98332)
@@ -55,7 +55,6 @@
virtual void sizeDidChange();
virtual void deviceScaleFactorDidChange();
virtual void visibilityDidChange();
- virtual void setPageIsVisible(bool);
virtual void setBackingStoreIsDiscardable(bool);
virtual void waitForBackingStoreUpdateOnNextPaint();
Modified: trunk/Source/WebKit2/UIProcess/TiledDrawingAreaProxy.cpp (98331 => 98332)
--- trunk/Source/WebKit2/UIProcess/TiledDrawingAreaProxy.cpp 2011-10-25 09:54:27 UTC (rev 98331)
+++ trunk/Source/WebKit2/UIProcess/TiledDrawingAreaProxy.cpp 2011-10-25 11:01:51 UTC (rev 98332)
@@ -47,7 +47,6 @@
TiledDrawingAreaProxy::TiledDrawingAreaProxy(PlatformWebView* webView, WebPageProxy* webPageProxy)
: DrawingAreaProxy(DrawingAreaTypeTiled, webPageProxy)
, m_isWaitingForDidSetFrameNotification(false)
- , m_isVisible(true)
, m_webView(webView)
{
}
@@ -93,29 +92,6 @@
notImplemented();
}
-void TiledDrawingAreaProxy::setPageIsVisible(bool isVisible)
-{
- WebPageProxy* page = this->page();
-
- if (isVisible == m_isVisible)
- return;
-
- m_isVisible = isVisible;
- if (!page || !page->isValid())
- return;
-
- if (!m_isVisible) {
- // Tell the web process that it doesn't need to paint anything for now.
- page->process()->send(Messages::DrawingArea::SuspendPainting(), page->pageID());
- return;
- }
-
- // The page is now visible.
- page->process()->send(Messages::DrawingArea::ResumePainting(), page->pageID());
-
- // FIXME: We should request a full repaint here if needed.
-}
-
} // namespace WebKit
#endif
Modified: trunk/Source/WebKit2/UIProcess/TiledDrawingAreaProxy.h (98331 => 98332)
--- trunk/Source/WebKit2/UIProcess/TiledDrawingAreaProxy.h 2011-10-25 09:54:27 UTC (rev 98331)
+++ trunk/Source/WebKit2/UIProcess/TiledDrawingAreaProxy.h 2011-10-25 11:01:51 UTC (rev 98332)
@@ -87,7 +87,6 @@
// DrawingAreaProxy
virtual void sizeDidChange();
virtual void deviceScaleFactorDidChange();
- virtual void setPageIsVisible(bool isVisible);
virtual void createTile(int tileID, const UpdateInfo&);
virtual void updateTile(int tileID, const UpdateInfo&);
@@ -97,7 +96,6 @@
private:
bool m_isWaitingForDidSetFrameNotification;
- bool m_isVisible;
PlatformWebView* m_webView;
#if PLATFORM(QT)
Modified: trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp (98331 => 98332)
--- trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp 2011-10-25 09:54:27 UTC (rev 98331)
+++ trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp 2011-10-25 11:01:51 UTC (rev 98332)
@@ -718,7 +718,6 @@
if (isVisible != m_isVisible) {
m_isVisible = isVisible;
m_drawingArea->visibilityDidChange();
- m_drawingArea->setPageIsVisible(isVisible);
if (!m_isVisible) {
// If we've started the responsiveness timer as part of telling the web process to update the backing store
Modified: trunk/Source/WebKit2/UIProcess/qt/QtWebPageProxy.cpp (98331 => 98332)
--- trunk/Source/WebKit2/UIProcess/qt/QtWebPageProxy.cpp 2011-10-25 09:54:27 UTC (rev 98331)
+++ trunk/Source/WebKit2/UIProcess/qt/QtWebPageProxy.cpp 2011-10-25 11:01:51 UTC (rev 98332)
@@ -696,9 +696,4 @@
m_viewInterface->didReceiveViewportArguments(args);
}
-void QtWebPageProxy::setPageIsVisible(bool isVisible)
-{
- m_webPageProxy->drawingArea()->setPageIsVisible(isVisible);
-}
-
#include "moc_QtWebPageProxy.cpp"
Modified: trunk/Source/WebKit2/UIProcess/qt/QtWebPageProxy.h (98331 => 98332)
--- trunk/Source/WebKit2/UIProcess/qt/QtWebPageProxy.h 2011-10-25 09:54:27 UTC (rev 98331)
+++ trunk/Source/WebKit2/UIProcess/qt/QtWebPageProxy.h 2011-10-25 11:01:51 UTC (rev 98332)
@@ -170,8 +170,6 @@
QWKHistory* history() const;
- void setPageIsVisible(bool);
-
public Q_SLOTS:
void webActionTriggered(bool checked);