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

Unified Diff: Source/core/frame/FrameView.cpp

Issue 1171963003: Fix AXScrollbar from being recreated right after removal Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 6 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/frame/FrameView.cpp
diff --git a/Source/core/frame/FrameView.cpp b/Source/core/frame/FrameView.cpp
index 19bfd555f4cc5e0ba3a61be3171147485f9590a8..2ef6ce1c136f02023b07327a3a3bdea306aa9642 100644
--- a/Source/core/frame/FrameView.cpp
+++ b/Source/core/frame/FrameView.cpp
@@ -3020,10 +3020,8 @@ void FrameView::didAddScrollbar(Scrollbar* scrollbar, ScrollbarOrientation orien
void FrameView::willRemoveScrollbar(Scrollbar* scrollbar, ScrollbarOrientation orientation)
{
ScrollableArea::willRemoveScrollbar(scrollbar, orientation);
- if (AXObjectCache* cache = axObjectCache()) {
+ if (AXObjectCache* cache = axObjectCache())
cache->remove(scrollbar);
- cache->handleScrollbarUpdate(this);
- }
}
void FrameView::setTopControlsViewportAdjustment(float adjustment)
@@ -3074,6 +3072,8 @@ void FrameView::setHasHorizontalScrollbar(bool hasBar)
adjustScrollbarsAvoidingResizerCount(-1);
removeChild(m_horizontalScrollbar.get());
m_horizontalScrollbar = nullptr;
+ if (AXObjectCache* cache = axObjectCache())
+ cache->handleScrollbarUpdate(this);
}
if (RuntimeEnabledFeatures::slimmingPaintEnabled())
@@ -3098,6 +3098,8 @@ void FrameView::setHasVerticalScrollbar(bool hasBar)
adjustScrollbarsAvoidingResizerCount(-1);
removeChild(m_verticalScrollbar.get());
m_verticalScrollbar = nullptr;
+ if (AXObjectCache* cache = axObjectCache())
+ cache->handleScrollbarUpdate(this);
}
if (RuntimeEnabledFeatures::slimmingPaintEnabled())
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698