diff --git a/Libraries/LibWeb/OutOfProcessWebView.cpp b/Libraries/LibWeb/OutOfProcessWebView.cpp index df59697373..fa760b2214 100644 --- a/Libraries/LibWeb/OutOfProcessWebView.cpp +++ b/Libraries/LibWeb/OutOfProcessWebView.cpp @@ -60,6 +60,12 @@ void OutOfProcessWebView::load_html(const StringView& html, const URL& url) client().post_message(Messages::WebContentServer::LoadHTML(html, url)); } +void OutOfProcessWebView::load_empty_document() +{ + m_url = {}; + client().post_message(Messages::WebContentServer::LoadHTML("", {})); +} + void OutOfProcessWebView::paint_event(GUI::PaintEvent& event) { GUI::ScrollableWidget::paint_event(event); diff --git a/Libraries/LibWeb/OutOfProcessWebView.h b/Libraries/LibWeb/OutOfProcessWebView.h index 56efc3680e..b39f611ad2 100644 --- a/Libraries/LibWeb/OutOfProcessWebView.h +++ b/Libraries/LibWeb/OutOfProcessWebView.h @@ -47,6 +47,7 @@ public: void load(const URL&); void load_html(const StringView&, const URL&); + void load_empty_document(); void notify_server_did_layout(Badge, const Gfx::IntSize& content_size); void notify_server_did_paint(Badge, i32 shbuf_id);