chromium/third_party/blink/renderer/core/layout/hit_test_result.cc

/*
 * Copyright (C) 2006, 2008, 2011 Apple Inc. All rights reserved.
 * Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies)
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Library General Public
 * License as published by the Free Software Foundation; either
 * version 2 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Library General Public License for more details.
 *
 * You should have received a copy of the GNU Library General Public License
 * along with this library; see the file COPYING.LIB.  If not, write to
 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
 * Boston, MA 02110-1301, USA.
 *
 */

#include "third_party/blink/renderer/core/layout/hit_test_result.h"

#include "cc/base/region.h"
#include "third_party/abseil-cpp/absl/types/variant.h"
#include "third_party/blink/renderer/core/display_lock/display_lock_utilities.h"
#include "third_party/blink/renderer/core/dom/flat_tree_traversal.h"
#include "third_party/blink/renderer/core/dom/pseudo_element.h"
#include "third_party/blink/renderer/core/dom/shadow_root.h"
#include "third_party/blink/renderer/core/editing/editing_utilities.h"
#include "third_party/blink/renderer/core/editing/frame_selection.h"
#include "third_party/blink/renderer/core/editing/position_with_affinity.h"
#include "third_party/blink/renderer/core/editing/text_affinity.h"
#include "third_party/blink/renderer/core/editing/visible_units.h"
#include "third_party/blink/renderer/core/frame/local_frame.h"
#include "third_party/blink/renderer/core/frame/visual_viewport.h"
#include "third_party/blink/renderer/core/html/forms/html_input_element.h"
#include "third_party/blink/renderer/core/html/forms/html_text_area_element.h"
#include "third_party/blink/renderer/core/html/html_area_element.h"
#include "third_party/blink/renderer/core/html/html_embed_element.h"
#include "third_party/blink/renderer/core/html/html_image_element.h"
#include "third_party/blink/renderer/core/html/html_map_element.h"
#include "third_party/blink/renderer/core/html/html_object_element.h"
#include "third_party/blink/renderer/core/html/media/html_media_element.h"
#include "third_party/blink/renderer/core/html/media/media_source_handle.h"
#include "third_party/blink/renderer/core/html/parser/html_parser_idioms.h"
#include "third_party/blink/renderer/core/html_names.h"
#include "third_party/blink/renderer/core/input_type_names.h"
#include "third_party/blink/renderer/core/layout/hit_test_location.h"
#include "third_party/blink/renderer/core/layout/layout_block.h"
#include "third_party/blink/renderer/core/layout/layout_embedded_content.h"
#include "third_party/blink/renderer/core/layout/layout_image.h"
#include "third_party/blink/renderer/core/layout/layout_view.h"
#include "third_party/blink/renderer/core/layout/physical_box_fragment.h"
#include "third_party/blink/renderer/core/layout/svg/layout_svg_image.h"
#include "third_party/blink/renderer/core/page/page.h"
#include "third_party/blink/renderer/core/page/scrolling/top_document_root_scroller_controller.h"
#include "third_party/blink/renderer/core/scroll/scrollbar.h"
#include "third_party/blink/renderer/core/svg/svg_element.h"
#include "third_party/blink/renderer/platform/mediastream/media_stream_descriptor.h"
#include "ui/gfx/geometry/rect_conversions.h"

namespace blink {

FormControlType;

namespace {

bool HasImageSourceURL(const Node& node) {}

}  // namespace

HitTestResult::HitTestResult()
    :{}

HitTestResult::HitTestResult(const HitTestRequest& other_request,
                             const HitTestLocation& location)
    :{}

HitTestResult::HitTestResult(const HitTestResult& other)
    :{}

HitTestResult::~HitTestResult() = default;

HitTestResult& HitTestResult::operator=(const HitTestResult& other) {}

bool HitTestResult::EqualForCacheability(const HitTestResult& other) const {}

void HitTestResult::CacheValues(const HitTestResult& other) {}

void HitTestResult::PopulateFromCachedResult(const HitTestResult& other) {}

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

void HitTestResult::SetNodeAndPosition(Node* node,
                                       const PhysicalBoxFragment* box_fragment,
                                       const PhysicalOffset& position) {}

void HitTestResult::OverrideNodeAndPosition(Node* node,
                                            PhysicalOffset position) {}

PositionWithAffinity HitTestResult::GetPosition() const {}

PositionWithAffinity HitTestResult::GetPositionForInnerNodeOrImageMapImage()
    const {}

void HitTestResult::SetToShadowHostIfInUAShadowRoot() {}

CompositorElementId HitTestResult::GetScrollableContainer() const {}

HTMLAreaElement* HitTestResult::ImageAreaForImage() const {}

void HitTestResult::SetInnerNode(Node* n) {}

void HitTestResult::SetURLElement(Element* n) {}

void HitTestResult::SetScrollbar(Scrollbar* s) {}

LocalFrame* HitTestResult::InnerNodeFrame() const {}

bool HitTestResult::IsSelected(const HitTestLocation& location) const {}

String HitTestResult::Title(TextDirection& dir) const {}

const AtomicString& HitTestResult::AltDisplayString() const {}

Image* HitTestResult::GetImage() const {}

Image* HitTestResult::GetImage(const Node* node) {}

gfx::Rect HitTestResult::ImageRect() const {}

KURL HitTestResult::AbsoluteImageURL(const Node* node) {}

KURL HitTestResult::AbsoluteImageURL() const {}

KURL HitTestResult::AbsoluteMediaURL() const {}

MediaStreamDescriptor* HitTestResult::GetMediaStreamDescriptor() const {}

MediaSourceHandle* HitTestResult::GetMediaSourceHandle() const {}

HTMLMediaElement* HitTestResult::MediaElement() const {}

KURL HitTestResult::AbsoluteLinkURL() const {}

bool HitTestResult::IsLiveLink() const {}

bool HitTestResult::IsOverLink() const {}

String HitTestResult::TextContent() const {}

// FIXME: This function needs a better name and may belong in a different class.
// It's not really isContentEditable(); it's more like needsEditingContextMenu.
// In many ways, this function would make more sense in the ContextMenu class,
// except that WebElementDictionary hooks into it. Anyway, we should architect
// this better.
bool HitTestResult::IsContentEditable() const {}

std::tuple<bool, ListBasedHitTestBehavior>
HitTestResult::AddNodeToListBasedTestResultInternal(
    Node* node,
    const HitTestLocation& location) {}

ListBasedHitTestBehavior HitTestResult::AddNodeToListBasedTestResult(
    Node* node,
    const HitTestLocation& location,
    const PhysicalRect& rect) {}

ListBasedHitTestBehavior HitTestResult::AddNodeToListBasedTestResult(
    Node* node,
    const HitTestLocation& location,
    const gfx::QuadF& quad) {}

ListBasedHitTestBehavior HitTestResult::AddNodeToListBasedTestResult(
    Node* node,
    const HitTestLocation& location,
    const cc::Region& region) {}

void HitTestResult::Append(const HitTestResult& other) {}

const HitTestResult::NodeSet& HitTestResult::ListBasedTestResult() const {}

HitTestResult::NodeSet& HitTestResult::MutableListBasedTestResult() {}

HitTestLocation HitTestResult::ResolveRectBasedTest(
    Node* resolved_inner_node,
    const PhysicalOffset& resolved_point_in_main_frame) {}

Node* HitTestResult::InnerNodeOrImageMapImage() const {}

}  // namespace blink