1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-10 05:27:35 +00:00

WebContent: Added IPC calls for getting source

This commit is contained in:
Brandon Scott 2021-02-23 06:14:12 -06:00 committed by Andreas Kling
parent a032c836c4
commit 306501fd4a
4 changed files with 10 additions and 0 deletions

View file

@ -209,4 +209,11 @@ void ClientConnection::handle(const Messages::WebContentServer::DebugRequest& me
}
}
void ClientConnection::handle(const Messages::WebContentServer::GetSource&)
{
if (auto* doc = page().main_frame().document()) {
post_message(Messages::WebContentClient::DidGetSource(doc->url(), doc->source()));
}
}
}