chromium/third_party/blink/renderer/core/annotation/annotation_agent_impl.cc

// Copyright 2022 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "third_party/blink/renderer/core/annotation/annotation_agent_impl.h"

#include "base/memory/scoped_refptr.h"
#include "base/task/single_thread_task_runner.h"
#include "base/trace_event/typed_macros.h"
#include "third_party/blink/public/mojom/scroll/scroll_into_view_params.mojom-blink.h"
#include "third_party/blink/renderer/core/annotation/annotation_agent_container_impl.h"
#include "third_party/blink/renderer/core/annotation/annotation_selector.h"
#include "third_party/blink/renderer/core/display_lock/display_lock_utilities.h"
#include "third_party/blink/renderer/core/dom/document.h"
#include "third_party/blink/renderer/core/dom/node.h"
#include "third_party/blink/renderer/core/editing/ephemeral_range.h"
#include "third_party/blink/renderer/core/editing/markers/document_marker_controller.h"
#include "third_party/blink/renderer/core/editing/markers/text_fragment_marker.h"
#include "third_party/blink/renderer/core/editing/range_in_flat_tree.h"
#include "third_party/blink/renderer/core/editing/visible_units.h"
#include "third_party/blink/renderer/core/execution_context/execution_context.h"
#include "third_party/blink/renderer/core/frame/local_frame.h"
#include "third_party/blink/renderer/core/frame/web_feature.h"
#include "third_party/blink/renderer/core/highlight/highlight_style_utils.h"
#include "third_party/blink/renderer/core/html/html_details_element.h"
#include "third_party/blink/renderer/core/layout/geometry/physical_rect.h"
#include "third_party/blink/renderer/core/layout/layout_object.h"
#include "third_party/blink/renderer/core/layout/layout_text.h"
#include "third_party/blink/renderer/core/layout/layout_view.h"
#include "third_party/blink/renderer/core/scroll/scroll_alignment.h"
#include "third_party/blink/renderer/core/scroll/scroll_into_view_util.h"
#include "third_party/blink/renderer/core/scroll/scrollable_area.h"
#include "third_party/blink/renderer/platform/heap/persistent.h"
#include "third_party/blink/renderer/platform/heap/visitor.h"
#include "third_party/blink/renderer/platform/instrumentation/use_counter.h"

namespace blink {

namespace {
bool IsValidRange(const RangeInFlatTree* range) {}

// There are several cases where text isn't visible/presented to the user but
// does appear findable to FindBuffer. The TextFinder use case wants to prevent
// offering scrolls to these sections as its confusing (in fact, document
// Markers will avoid creating a highlight for these, despite the fact we can
// scroll to it). We probably want to do this for general SharedHighlights as
// well but that will require some more thought and spec changes but we can
// experiment with this for TextFinder to see how it works.
bool IsValidRangeForTextFinder(const RangeInFlatTree* range) {}
}  // namespace

AnnotationAgentImpl::AnnotationAgentImpl(
    AnnotationAgentContainerImpl& owning_container,
    mojom::blink::AnnotationType annotation_type,
    AnnotationSelector& selector,
    AnnotationAgentContainerImpl::PassKey)
    :{}

void AnnotationAgentImpl::Trace(Visitor* visitor) const {}

void AnnotationAgentImpl::Bind(
    mojo::PendingRemote<mojom::blink::AnnotationAgentHost> host_remote,
    mojo::PendingReceiver<mojom::blink::AnnotationAgent> agent_receiver) {}

void AnnotationAgentImpl::Attach(AnnotationAgentContainerImpl::PassKey) {}

bool AnnotationAgentImpl::IsAttached() const {}

bool AnnotationAgentImpl::IsAttachmentPending() const {}

bool AnnotationAgentImpl::IsBoundForTesting() const {}

void AnnotationAgentImpl::Remove() {}

void AnnotationAgentImpl::ScrollIntoView() const {}

void AnnotationAgentImpl::DidFinishFindRange(const RangeInFlatTree* range) {}

bool AnnotationAgentImpl::NeedsDOMMutationToAttach() const {}

void AnnotationAgentImpl::PerformPreAttachDOMMutation() {}

void AnnotationAgentImpl::ProcessAttachmentFinished() {}

bool AnnotationAgentImpl::IsRemoved() const {}

}  // namespace blink