1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-23 11:55:08 +00:00
serenity/Userland/Libraries/LibWeb/Internals/Inspector.h
Timothy Flynn ffdc2d8add LibWeb+LibWebView+WebContent: Add an Inspector IDL object to the Window
This is an internal object that must be explicitly enabled by the chrome
before it is added to the Window. The Inspector object will be used by a
special WebView that will replace all chrome-specific inspector windows.
The IDL defines methods that this WebView will need to inform the chrome
of various events, such as the user clicking a DOM node.
2023-11-24 08:37:19 +01:00

30 lines
637 B
C++

/*
* Copyright (c) 2023, Tim Flynn <trflynn89@serenityos.org>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#pragma once
#include <LibJS/Forward.h>
#include <LibWeb/Bindings/PlatformObject.h>
namespace Web::Internals {
class Inspector final : public Bindings::PlatformObject {
WEB_PLATFORM_OBJECT(Inspector, Bindings::PlatformObject);
JS_DECLARE_ALLOCATOR(Inspector);
public:
virtual ~Inspector() override;
void inspector_loaded();
void inspect_dom_node(i32 node_id, Optional<i32> const& pseudo_element);
private:
explicit Inspector(JS::Realm&);
virtual void initialize(JS::Realm&) override;
};
}