Commit 6d36ece1 authored by Philip Rogers's avatar Philip Rogers Committed by Commit Bot

[RootLayerScrolls] Remove deadcode in LocalFrameView

This was generated using:
https://chromium-coverage.appspot.com/reports/572002/linux/chromium/src/third_party/blink/renderer/core/frame/local_frame_view.cc.html

BUG=823365

Change-Id: I136ba88950e2d042fd330cedb88614562af2e264
Reviewed-on: https://chromium-review.googlesource.com/1125309Reviewed-by: default avatarStefan Zager <szager@chromium.org>
Commit-Queue: Philip Rogers <pdr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#572419}
parent 52db2279
......@@ -222,9 +222,6 @@ LocalFrameView::LocalFrameView(LocalFrame& frame, IntRect frame_rect)
sticky_position_object_count_(0),
input_events_scale_factor_for_emulation_(1),
layout_size_fixed_to_frame_size_(true),
did_scroll_timer_(frame.GetTaskRunner(TaskType::kInternalDefault),
this,
&LocalFrameView::DidScrollTimerFired),
needs_update_geometries_(false),
root_layer_did_scroll_(false),
frame_timing_requests_dirty_(true),
......@@ -412,7 +409,6 @@ void LocalFrameView::Dispose() {
auto_size_info_.Clear();
post_layout_tasks_timer_.Stop();
did_scroll_timer_.Stop();
// FIXME: Do we need to do something here for OOPI?
HTMLFrameOwnerElement* owner_element = frame_->DeprecatedLocalOwner();
......@@ -560,37 +556,6 @@ CompositorAnimationTimeline* LocalFrameView::GetCompositorAnimationTimeline()
return c ? c->GetCompositorAnimationTimeline() : nullptr;
}
bool LocalFrameView::ShouldUseCustomScrollbars(
Element*& custom_scrollbar_element) const {
custom_scrollbar_element = nullptr;
if (Settings* settings = frame_->GetSettings()) {
if (!settings->GetAllowCustomScrollbarInMainFrame() &&
frame_->IsMainFrame())
return false;
}
Document* doc = frame_->GetDocument();
// Try the <body> element first as a scrollbar source.
Element* body = doc ? doc->body() : nullptr;
if (body && body->GetLayoutObject() &&
body->GetLayoutObject()->Style()->HasPseudoStyle(kPseudoIdScrollbar)) {
custom_scrollbar_element = body;
return true;
}
// If the <body> didn't have a custom style, then the root element might.
Element* doc_element = doc ? doc->documentElement() : nullptr;
if (doc_element && doc_element->GetLayoutObject() &&
doc_element->GetLayoutObject()->Style()->HasPseudoStyle(
kPseudoIdScrollbar)) {
custom_scrollbar_element = doc_element;
return true;
}
return false;
}
void LocalFrameView::SetLayoutOverflowSize(const IntSize& size) {
if (size == layout_overflow_size_)
return;
......@@ -1628,13 +1593,6 @@ void LocalFrameView::SetLayoutSizeFixedToFrameSize(bool is_fixed) {
SetLayoutSizeInternal(Size());
}
void LocalFrameView::DidScrollTimerFired(TimerBase*) {
if (frame_->GetDocument() && frame_->GetDocument()->GetLayoutView())
frame_->GetDocument()->Fetcher()->UpdateAllImageResourcePriorities();
GetFrame().Loader().SaveScrollAnchor();
}
static CompositedSelection ComputeCompositedSelection(LocalFrame& frame) {
if (!frame.View() || frame.View()->ShouldThrottleRendering())
return {};
......@@ -3575,11 +3533,6 @@ void LocalFrameView::DidChangeScrollOffset() {
GetFrame().GetPage()->GetChromeClient().MainFrameScrollOffsetChanged();
}
bool LocalFrameView::ShouldIgnoreOverflowHidden() const {
return frame_->GetSettings()->GetIgnoreMainFrameOverflowHiddenQuirk() &&
frame_->IsMainFrame();
}
ScrollableArea* LocalFrameView::ScrollableAreaWithElementId(
const CompositorElementId& id) {
// Check for the layout viewport, which may not be in scrollable_areas_ if it
......@@ -3879,14 +3832,6 @@ RootFrameViewport* LocalFrameView::GetRootFrameViewport() {
return viewport_scrollable_area_.Get();
}
LayoutObject* LocalFrameView::ViewportLayoutObject() const {
if (Document* document = GetFrame().GetDocument()) {
if (Element* element = document->ViewportDefiningElement())
return element->GetLayoutObject();
}
return nullptr;
}
void LocalFrameView::CollectAnnotatedRegions(
LayoutObject& layout_object,
Vector<AnnotatedRegionValue>& regions) const {
......
......@@ -711,18 +711,10 @@ class CORE_EXPORT LocalFrameView final
bool ProcessUrlFragmentHelper(const String&, UrlFragmentBehavior);
bool ParseCSSFragmentIdentifier(const String&, String*);
Element* FindCSSFragmentAnchor(const AtomicString&, Document*);
void DidScrollTimerFired(TimerBase*);
void UpdateCompositedSelectionIfNeeded();
void SetNeedsCompositingUpdate(CompositingUpdateType);
// Returns true if the frame should use custom scrollbars. If true, sets
// customScrollbarElement to the element that supplies the scrollbar's style
// information.
bool ShouldUseCustomScrollbars(Element*& custom_scrollbar_element) const;
bool ShouldIgnoreOverflowHidden() const;
AXObjectCache* ExistingAXObjectCache() const;
void SetLayoutSizeInternal(const IntSize&);
......@@ -732,10 +724,6 @@ class CORE_EXPORT LocalFrameView final
void PrepareLayoutAnalyzer();
std::unique_ptr<TracedValue> AnalyzerCounters();
// LayoutObject for the viewport-defining element (see
// Document::viewportDefiningElement).
LayoutObject* ViewportLayoutObject() const;
void CollectAnnotatedRegions(LayoutObject&,
Vector<AnnotatedRegionValue>&) const;
......@@ -822,8 +810,6 @@ class CORE_EXPORT LocalFrameView final
IntSize initial_viewport_size_;
bool layout_size_fixed_to_frame_size_;
TaskRunnerTimer<LocalFrameView> did_scroll_timer_;
bool needs_update_geometries_;
#if DCHECK_IS_ON()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment