Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1246)

Unified Diff: Source/core/rendering/RenderLayerScrollableArea.cpp

Issue 603193005: Move the Widget hierarchy to the Oilpan heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add ~Scrollbar assert Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/rendering/RenderLayerScrollableArea.cpp
diff --git a/Source/core/rendering/RenderLayerScrollableArea.cpp b/Source/core/rendering/RenderLayerScrollableArea.cpp
index 308e7016e74a1e8f5cd0b1f9acb5855104f009e1..07d732626f6e91b819074c3a11cae6bbcecb1ce2 100644
--- a/Source/core/rendering/RenderLayerScrollableArea.cpp
+++ b/Source/core/rendering/RenderLayerScrollableArea.cpp
@@ -357,7 +357,7 @@ void RenderLayerScrollableArea::setScrollOffset(const IntPoint& newScrollOffset)
LocalFrame* frame = box().frame();
ASSERT(frame);
- RefPtr<FrameView> frameView = box().frameView();
+ RefPtrWillBeRawPtr<FrameView> frameView = box().frameView();
TRACE_EVENT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), "ScrollLayer", "data", InspectorScrollLayerEvent::data(&box()));
// FIXME(361045): remove InspectorInstrumentation calls once DevTools Timeline migrates to tracing.
@@ -849,9 +849,9 @@ static inline RenderObject* rendererForScrollbar(RenderObject& renderer)
return &renderer;
}
-PassRefPtr<Scrollbar> RenderLayerScrollableArea::createScrollbar(ScrollbarOrientation orientation)
+PassRefPtrWillBeRawPtr<Scrollbar> RenderLayerScrollableArea::createScrollbar(ScrollbarOrientation orientation)
{
- RefPtr<Scrollbar> widget;
+ RefPtrWillBeRawPtr<Scrollbar> widget = nullptr;
RenderObject* actualRenderer = rendererForScrollbar(box());
bool hasCustomScrollbarStyle = actualRenderer->isBox() && actualRenderer->style()->hasPseudoStyle(SCROLLBAR);
if (hasCustomScrollbarStyle) {
@@ -872,7 +872,7 @@ PassRefPtr<Scrollbar> RenderLayerScrollableArea::createScrollbar(ScrollbarOrient
void RenderLayerScrollableArea::destroyScrollbar(ScrollbarOrientation orientation)
{
- RefPtr<Scrollbar>& scrollbar = orientation == HorizontalScrollbar ? m_hBar : m_vBar;
+ RefPtrWillBePersistent<Scrollbar>& scrollbar = orientation == HorizontalScrollbar ? m_hBar : m_vBar;
if (!scrollbar)
return;

Powered by Google App Engine
This is Rietveld 408576698