Diff
Modified: trunk/Source/WebCore/ChangeLog (105756 => 105757)
--- trunk/Source/WebCore/ChangeLog 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebCore/ChangeLog 2012-01-24 18:54:43 UTC (rev 105757)
@@ -1,3 +1,29 @@
+2012-01-23 Simon Fraser <[email protected]>
+
+ Show layer borders for scrollbar layers
+ https://bugs.webkit.org/show_bug.cgi?id=76888
+
+ Reviewed by Beth Dakin.
+
+ When compositing layer borders are showing, show the borders
+ for scrollbars layers. This reduces confusion about whether scrollbars
+ are rendering into their own layers.
+
+ Requires a new parameter to two GraphicsLayerClient methods.
+
+ * platform/graphics/GraphicsLayer.h:
+ (WebCore::GraphicsLayer::showDebugBorders):
+ (WebCore::GraphicsLayer::showRepaintCounter):
+ * platform/graphics/GraphicsLayerClient.h:
+ * rendering/RenderLayerBacking.cpp:
+ (WebCore::RenderLayerBacking::showDebugBorders):
+ (WebCore::RenderLayerBacking::showRepaintCounter):
+ * rendering/RenderLayerBacking.h:
+ * rendering/RenderLayerCompositor.cpp:
+ (WebCore::RenderLayerCompositor::showDebugBorders):
+ (WebCore::RenderLayerCompositor::showRepaintCounter):
+ * rendering/RenderLayerCompositor.h:
+
2012-01-24 David Levin <[email protected]>
[windows] Convert usage of GetDC to HWndDC Part 3.
Modified: trunk/Source/WebCore/platform/graphics/GraphicsLayer.h (105756 => 105757)
--- trunk/Source/WebCore/platform/graphics/GraphicsLayer.h 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebCore/platform/graphics/GraphicsLayer.h 2012-01-24 18:54:43 UTC (rev 105757)
@@ -370,8 +370,8 @@
virtual void setContentsOrientation(CompositingCoordinatesOrientation orientation) { m_contentsOrientation = orientation; }
CompositingCoordinatesOrientation contentsOrientation() const { return m_contentsOrientation; }
- bool showDebugBorders() const { return m_client ? m_client->showDebugBorders() : false; }
- bool showRepaintCounter() const { return m_client ? m_client->showRepaintCounter() : false; }
+ bool showDebugBorders() const { return m_client ? m_client->showDebugBorders(this) : false; }
+ bool showRepaintCounter() const { return m_client ? m_client->showRepaintCounter(this) : false; }
void updateDebugIndicators();
Modified: trunk/Source/WebCore/platform/graphics/GraphicsLayerClient.h (105756 => 105757)
--- trunk/Source/WebCore/platform/graphics/GraphicsLayerClient.h 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebCore/platform/graphics/GraphicsLayerClient.h 2012-01-24 18:54:43 UTC (rev 105757)
@@ -71,8 +71,8 @@
// Page scale factor.
virtual float pageScaleFactor() const { return 1; }
- virtual bool showDebugBorders() const = 0;
- virtual bool showRepaintCounter() const = 0;
+ virtual bool showDebugBorders(const GraphicsLayer*) const = 0;
+ virtual bool showRepaintCounter(const GraphicsLayer*) const = 0;
};
} // namespace WebCore
Modified: trunk/Source/WebCore/rendering/RenderLayerBacking.cpp (105756 => 105757)
--- trunk/Source/WebCore/rendering/RenderLayerBacking.cpp 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebCore/rendering/RenderLayerBacking.cpp 2012-01-24 18:54:43 UTC (rev 105757)
@@ -1179,12 +1179,12 @@
compositor()->didFlushChangesForLayer(m_owningLayer);
}
-bool RenderLayerBacking::showDebugBorders() const
+bool RenderLayerBacking::showDebugBorders(const GraphicsLayer*) const
{
return compositor() ? compositor()->compositorShowDebugBorders() : false;
}
-bool RenderLayerBacking::showRepaintCounter() const
+bool RenderLayerBacking::showRepaintCounter(const GraphicsLayer*) const
{
return compositor() ? compositor()->compositorShowRepaintCounter() : false;
}
Modified: trunk/Source/WebCore/rendering/RenderLayerBacking.h (105756 => 105757)
--- trunk/Source/WebCore/rendering/RenderLayerBacking.h 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebCore/rendering/RenderLayerBacking.h 2012-01-24 18:54:43 UTC (rev 105757)
@@ -133,8 +133,8 @@
virtual float pageScaleFactor() const;
virtual void didCommitChangesForLayer(const GraphicsLayer*) const;
- virtual bool showDebugBorders() const;
- virtual bool showRepaintCounter() const;
+ virtual bool showDebugBorders(const GraphicsLayer*) const;
+ virtual bool showRepaintCounter(const GraphicsLayer*) const;
LayoutRect contentsBox() const;
Modified: trunk/Source/WebCore/rendering/RenderLayerCompositor.cpp (105756 => 105757)
--- trunk/Source/WebCore/rendering/RenderLayerCompositor.cpp 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebCore/rendering/RenderLayerCompositor.cpp 2012-01-24 18:54:43 UTC (rev 105757)
@@ -1623,6 +1623,22 @@
}
}
+bool RenderLayerCompositor::showDebugBorders(const GraphicsLayer* layer) const
+{
+ if (layer == m_layerForHorizontalScrollbar || layer == m_layerForVerticalScrollbar || layer == m_layerForScrollCorner)
+ return m_showDebugBorders;
+
+ return false;
+}
+
+bool RenderLayerCompositor::showRepaintCounter(const GraphicsLayer* layer) const
+{
+ if (layer == m_layerForHorizontalScrollbar || layer == m_layerForVerticalScrollbar || layer == m_layerForScrollCorner)
+ return m_showDebugBorders;
+
+ return false;
+}
+
float RenderLayerCompositor::deviceScaleFactor() const
{
Frame* frame = m_renderView->frameView()->frame();
Modified: trunk/Source/WebCore/rendering/RenderLayerCompositor.h (105756 => 105757)
--- trunk/Source/WebCore/rendering/RenderLayerCompositor.h 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebCore/rendering/RenderLayerCompositor.h 2012-01-24 18:54:43 UTC (rev 105757)
@@ -217,10 +217,8 @@
virtual void notifySyncRequired(const GraphicsLayer*) { scheduleLayerFlush(); }
virtual void paintContents(const GraphicsLayer*, GraphicsContext&, GraphicsLayerPaintingPhase, const LayoutRect&);
- // These calls return false always. They are saying that the layers associated with this client
- // (the clipLayer and scrollLayer) should never show debugging info.
- virtual bool showDebugBorders() const { return false; }
- virtual bool showRepaintCounter() const { return false; }
+ virtual bool showDebugBorders(const GraphicsLayer*) const;
+ virtual bool showRepaintCounter(const GraphicsLayer*) const;
// Whether the given RL needs a compositing layer.
bool needsToBeComposited(const RenderLayer*) const;
Modified: trunk/Source/WebKit/chromium/ChangeLog (105756 => 105757)
--- trunk/Source/WebKit/chromium/ChangeLog 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebKit/chromium/ChangeLog 2012-01-24 18:54:43 UTC (rev 105757)
@@ -1,3 +1,24 @@
+2012-01-23 Simon Fraser <[email protected]>
+
+ Show layer borders for scrollbar layers
+ https://bugs.webkit.org/show_bug.cgi?id=76888
+
+ Reviewed by Beth Dakin.
+
+ Update for new signature of GraphicsLayerClient::showDebugBorders()
+ and GraphicsLayerClient::showRepaintCounter().
+
+ * src/NonCompositedContentHost.cpp:
+ (WebKit::NonCompositedContentHost::showDebugBorders):
+ (WebKit::NonCompositedContentHost::showRepaintCounter):
+ * src/NonCompositedContentHost.h:
+ * src/PageOverlay.cpp:
+ (WebKit::OverlayGraphicsLayerClientImpl::showDebugBorders):
+ (WebKit::OverlayGraphicsLayerClientImpl::showRepaintCounter):
+ * tests/ImageLayerChromiumTest.cpp:
+ (WebCore::MockGraphicsLayerClient::showDebugBorders):
+ (WebCore::MockGraphicsLayerClient::showRepaintCounter):
+
2012-01-24 Vincent Scheib <[email protected]>
[Chromium] Add WebKit API for Pointer Lock
Modified: trunk/Source/WebKit/chromium/src/NonCompositedContentHost.cpp (105756 => 105757)
--- trunk/Source/WebKit/chromium/src/NonCompositedContentHost.cpp 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebKit/chromium/src/NonCompositedContentHost.cpp 2012-01-24 18:54:43 UTC (rev 105757)
@@ -151,12 +151,12 @@
m_graphicsLayer->updateDebugIndicators();
}
-bool NonCompositedContentHost::showDebugBorders() const
+bool NonCompositedContentHost::showDebugBorders(const WebCore::GraphicsLayer*) const
{
return m_showDebugBorders;
}
-bool NonCompositedContentHost::showRepaintCounter() const
+bool NonCompositedContentHost::showRepaintCounter(const WebCore::GraphicsLayer*) const
{
return false;
}
Modified: trunk/Source/WebKit/chromium/src/NonCompositedContentHost.h (105756 => 105757)
--- trunk/Source/WebKit/chromium/src/NonCompositedContentHost.h 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebKit/chromium/src/NonCompositedContentHost.h 2012-01-24 18:54:43 UTC (rev 105757)
@@ -71,8 +71,8 @@
virtual void notifyAnimationStarted(const WebCore::GraphicsLayer*, double time);
virtual void notifySyncRequired(const WebCore::GraphicsLayer*);
virtual void paintContents(const WebCore::GraphicsLayer*, WebCore::GraphicsContext&, WebCore::GraphicsLayerPaintingPhase, const WebCore::IntRect& clipRect);
- virtual bool showDebugBorders() const;
- virtual bool showRepaintCounter() const;
+ virtual bool showDebugBorders(const WebCore::GraphicsLayer*) const;
+ virtual bool showRepaintCounter(const WebCore::GraphicsLayer*) const;
WebCore::LayerChromium* scrollLayer();
Modified: trunk/Source/WebKit/chromium/src/PageOverlay.cpp (105756 => 105757)
--- trunk/Source/WebKit/chromium/src/PageOverlay.cpp 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebKit/chromium/src/PageOverlay.cpp 2012-01-24 18:54:43 UTC (rev 105757)
@@ -98,12 +98,12 @@
return m_webViewImpl->pageScaleFactor();
}
- virtual bool showDebugBorders() const
+ virtual bool showDebugBorders(const GraphicsLayer*) const
{
return m_webViewImpl->page()->settings()->showDebugBorders();
}
- virtual bool showRepaintCounter() const
+ virtual bool showRepaintCounter(const GraphicsLayer*) const
{
return m_webViewImpl->page()->settings()->showRepaintCounter();
}
Modified: trunk/Source/WebKit/chromium/tests/ImageLayerChromiumTest.cpp (105756 => 105757)
--- trunk/Source/WebKit/chromium/tests/ImageLayerChromiumTest.cpp 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebKit/chromium/tests/ImageLayerChromiumTest.cpp 2012-01-24 18:54:43 UTC (rev 105757)
@@ -41,8 +41,8 @@
virtual void notifyAnimationStarted(const GraphicsLayer*, double time) { }
virtual void notifySyncRequired(const GraphicsLayer*) { }
virtual void paintContents(const GraphicsLayer*, GraphicsContext&, GraphicsLayerPaintingPhase, const IntRect& inClip) { }
- virtual bool showDebugBorders() const { return false; }
- virtual bool showRepaintCounter() const { return false; }
+ virtual bool showDebugBorders(const GraphicsLayer*) const { return false; }
+ virtual bool showRepaintCounter(const GraphicsLayer*) const { return false; }
};
class TestImage : public Image {
Modified: trunk/Source/WebKit/win/ChangeLog (105756 => 105757)
--- trunk/Source/WebKit/win/ChangeLog 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebKit/win/ChangeLog 2012-01-24 18:54:43 UTC (rev 105757)
@@ -1,3 +1,18 @@
+2012-01-23 Simon Fraser <[email protected]>
+
+ Show layer borders for scrollbar layers
+ https://bugs.webkit.org/show_bug.cgi?id=76888
+
+ Reviewed by Beth Dakin.
+
+ Update for new signature of GraphicsLayerClient::showDebugBorders()
+ and GraphicsLayerClient::showRepaintCounter().
+
+ * WebView.cpp:
+ (WebView::showDebugBorders):
+ (WebView::showRepaintCounter):
+ * WebView.h:
+
2012-01-23 David Levin <[email protected]>
[windows] Convert usages of GetDC to HWndDC Part 2.
Modified: trunk/Source/WebKit/win/WebView.cpp (105756 => 105757)
--- trunk/Source/WebKit/win/WebView.cpp 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebKit/win/WebView.cpp 2012-01-24 18:54:43 UTC (rev 105757)
@@ -6628,12 +6628,12 @@
context.restore();
}
-bool WebView::showDebugBorders() const
+bool WebView::showDebugBorders(const GraphicsLayer*) const
{
return m_page->settings()->showDebugBorders();
}
-bool WebView::showRepaintCounter() const
+bool WebView::showRepaintCounter(const GraphicsLayer*) const
{
return m_page->settings()->showRepaintCounter();
}
Modified: trunk/Source/WebKit/win/WebView.h (105756 => 105757)
--- trunk/Source/WebKit/win/WebView.h 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebKit/win/WebView.h 2012-01-24 18:54:43 UTC (rev 105757)
@@ -994,8 +994,8 @@
virtual void notifyAnimationStarted(const WebCore::GraphicsLayer*, double time);
virtual void notifySyncRequired(const WebCore::GraphicsLayer*);
virtual void paintContents(const WebCore::GraphicsLayer*, WebCore::GraphicsContext&, WebCore::GraphicsLayerPaintingPhase, const WebCore::IntRect& inClip);
- virtual bool showDebugBorders() const;
- virtual bool showRepaintCounter() const;
+ virtual bool showDebugBorders(const WebCore::GraphicsLayer*) const;
+ virtual bool showRepaintCounter(const WebCore::GraphicsLayer*) const;
// CACFLayerTreeHostClient
virtual void flushPendingGraphicsLayerChanges();
Modified: trunk/Source/WebKit2/ChangeLog (105756 => 105757)
--- trunk/Source/WebKit2/ChangeLog 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebKit2/ChangeLog 2012-01-24 18:54:43 UTC (rev 105757)
@@ -1,3 +1,22 @@
+2012-01-23 Simon Fraser <[email protected]>
+
+ Show layer borders for scrollbar layers
+ https://bugs.webkit.org/show_bug.cgi?id=76888
+
+ Reviewed by Beth Dakin.
+
+ Update for new signatures of GraphicsLayerClient::showDebugBorders()
+ and GraphicsLayerClient::showRepaintCounter().
+
+ * UIProcess/LayerTreeHostProxy.h:
+ (WebKit::LayerTreeHostProxy::showDebugBorders):
+ (WebKit::LayerTreeHostProxy::showRepaintCounter):
+ * WebProcess/WebPage/ca/LayerTreeHostCA.cpp:
+ (WebKit::LayerTreeHostCA::showDebugBorders):
+ (WebKit::LayerTreeHostCA::showRepaintCounter):
+ * WebProcess/WebPage/ca/LayerTreeHostCA.h:
+ * WebProcess/WebPage/qt/LayerTreeHostQt.h:
+
2012-01-24 David Levin <[email protected]>
[windows] Convert usage of GetDC to HWndDC Part 3.
Modified: trunk/Source/WebKit2/UIProcess/LayerTreeHostProxy.h (105756 => 105757)
--- trunk/Source/WebKit2/UIProcess/LayerTreeHostProxy.h 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebKit2/UIProcess/LayerTreeHostProxy.h 2012-01-24 18:54:43 UTC (rev 105757)
@@ -78,8 +78,8 @@
// Reimplementations from WebCore::GraphicsLayerClient.
virtual void notifyAnimationStarted(const WebCore::GraphicsLayer*, double) { }
virtual void notifySyncRequired(const WebCore::GraphicsLayer*) { }
- virtual bool showDebugBorders() const { return false; }
- virtual bool showRepaintCounter() const { return false; }
+ virtual bool showDebugBorders(const WebCore::GraphicsLayer*) const { return false; }
+ virtual bool showRepaintCounter(const WebCore::GraphicsLayer*) const { return false; }
void paintContents(const WebCore::GraphicsLayer*, WebCore::GraphicsContext&, WebCore::GraphicsLayerPaintingPhase, const WebCore::IntRect&) { }
WebCore::RunLoop::Timer<LayerTreeHostProxy> m_animationTimer;
Modified: trunk/Source/WebKit2/WebProcess/WebPage/ca/LayerTreeHostCA.cpp (105756 => 105757)
--- trunk/Source/WebKit2/WebProcess/WebPage/ca/LayerTreeHostCA.cpp 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebKit2/WebProcess/WebPage/ca/LayerTreeHostCA.cpp 2012-01-24 18:54:43 UTC (rev 105757)
@@ -203,12 +203,12 @@
}
}
-bool LayerTreeHostCA::showDebugBorders() const
+bool LayerTreeHostCA::showDebugBorders(const GraphicsLayer*) const
{
return m_webPage->corePage()->settings()->showDebugBorders();
}
-bool LayerTreeHostCA::showRepaintCounter() const
+bool LayerTreeHostCA::showRepaintCounter(const GraphicsLayer*) const
{
return m_webPage->corePage()->settings()->showRepaintCounter();
}
Modified: trunk/Source/WebKit2/WebProcess/WebPage/ca/LayerTreeHostCA.h (105756 => 105757)
--- trunk/Source/WebKit2/WebProcess/WebPage/ca/LayerTreeHostCA.h 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebKit2/WebProcess/WebPage/ca/LayerTreeHostCA.h 2012-01-24 18:54:43 UTC (rev 105757)
@@ -73,8 +73,8 @@
virtual void notifyAnimationStarted(const WebCore::GraphicsLayer*, double time);
virtual void notifySyncRequired(const WebCore::GraphicsLayer*);
virtual void paintContents(const WebCore::GraphicsLayer*, WebCore::GraphicsContext&, WebCore::GraphicsLayerPaintingPhase, const WebCore::IntRect& clipRect);
- virtual bool showDebugBorders() const;
- virtual bool showRepaintCounter() const;
+ virtual bool showDebugBorders(const WebCore::GraphicsLayer*) const;
+ virtual bool showRepaintCounter(const WebCore::GraphicsLayer*) const;
virtual float deviceScaleFactor() const;
virtual void didCommitChangesForLayer(const WebCore::GraphicsLayer*) const { }
Modified: trunk/Source/WebKit2/WebProcess/WebPage/qt/LayerTreeHostQt.h (105756 => 105757)
--- trunk/Source/WebKit2/WebProcess/WebPage/qt/LayerTreeHostQt.h 2012-01-24 18:51:50 UTC (rev 105756)
+++ trunk/Source/WebKit2/WebProcess/WebPage/qt/LayerTreeHostQt.h 2012-01-24 18:54:43 UTC (rev 105757)
@@ -86,8 +86,8 @@
virtual void notifyAnimationStarted(const WebCore::GraphicsLayer*, double time);
virtual void notifySyncRequired(const WebCore::GraphicsLayer*);
virtual void paintContents(const WebCore::GraphicsLayer*, WebCore::GraphicsContext&, WebCore::GraphicsLayerPaintingPhase, const WebCore::IntRect& clipRect);
- virtual bool showDebugBorders() const;
- virtual bool showRepaintCounter() const;
+ virtual bool showDebugBorders(const WebCore::GraphicsLayer*) const;
+ virtual bool showRepaintCounter(const WebCore::GraphicsLayer*) const;
// LayerTreeHostQt
void createPageOverlayLayer();