ladybird/Userland/Libraries/LibWeb/Selection/Selection.cpp
Andrew Kaster 4bb6345b2f LibWeb: Remove unecessary dependence on Window from assorted classes
These classes only needed Window to get at its realm. Pass a realm
directly to construct Crypto, Encoding, HRT, IntersectionObserver,
NavigationTiming, Page, RequestIdleCallback, Selection, Streams, URL,
and XML classes.
2022-10-01 21:05:32 +01:00

144 lines
2.1 KiB
C++

/*
* Copyright (c) 2021, Andreas Kling <kling@serenityos.org>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#include <LibWeb/Bindings/Intrinsics.h>
#include <LibWeb/Selection/Selection.h>
namespace Web::Selection {
JS::NonnullGCPtr<Selection> Selection::create(JS::Realm& realm)
{
return *realm.heap().allocate<Selection>(realm, realm);
}
Selection::Selection(JS::Realm& realm)
: PlatformObject(realm)
{
set_prototype(&Bindings::cached_web_prototype(realm, "Selection"));
}
Selection::~Selection() = default;
DOM::Node* Selection::anchor_node()
{
TODO();
}
unsigned Selection::anchor_offset()
{
TODO();
}
DOM::Node* Selection::focus_node()
{
TODO();
}
unsigned Selection::focus_offset() const
{
TODO();
}
bool Selection::is_collapsed() const
{
TODO();
}
unsigned Selection::range_count() const
{
TODO();
}
String Selection::type() const
{
TODO();
}
DOM::Range* Selection::get_range_at(unsigned index)
{
(void)index;
TODO();
}
void Selection::add_range(DOM::Range&)
{
TODO();
}
void Selection::remove_range(DOM::Range&)
{
TODO();
}
void Selection::remove_all_ranges()
{
TODO();
}
void Selection::empty()
{
TODO();
}
void Selection::collapse(DOM::Node*, unsigned offset)
{
(void)offset;
TODO();
}
void Selection::set_position(DOM::Node*, unsigned offset)
{
(void)offset;
TODO();
}
void Selection::collapse_to_start()
{
TODO();
}
void Selection::collapse_to_end()
{
TODO();
}
void Selection::extend(DOM::Node&, unsigned offset)
{
(void)offset;
TODO();
}
void Selection::set_base_and_extent(DOM::Node& anchor_node, unsigned anchor_offset, DOM::Node& focus_node, unsigned focus_offset)
{
(void)anchor_node;
(void)anchor_offset;
(void)focus_node;
(void)focus_offset;
TODO();
}
void Selection::select_all_children(DOM::Node&)
{
TODO();
}
void Selection::delete_from_document()
{
TODO();
}
bool Selection::contains_node(DOM::Node&, bool allow_partial_containment) const
{
(void)allow_partial_containment;
TODO();
}
String Selection::to_string() const
{
TODO();
}
}