mirror of
https://github.com/RGBCube/serenity
synced 2025-07-24 21:47:43 +00:00
LibWeb: Call page_did_start_loading() before load_resource()
Otherwise we would sometimes (dependent on the load time, I believe) end up setting the document and eventually calling title change callbacks before communicating that the page started loading.
This commit is contained in:
parent
94a56c3aee
commit
56e69c4f2e
1 changed files with 2 additions and 2 deletions
|
@ -143,13 +143,13 @@ bool FrameLoader::load(const LoadRequest& request, Type type)
|
||||||
|
|
||||||
auto& url = request.url();
|
auto& url = request.url();
|
||||||
|
|
||||||
set_resource(ResourceLoader::the().load_resource(Resource::Type::Generic, request));
|
|
||||||
|
|
||||||
if (type == Type::Navigation) {
|
if (type == Type::Navigation) {
|
||||||
if (auto* page = frame().page())
|
if (auto* page = frame().page())
|
||||||
page->client().page_did_start_loading(url);
|
page->client().page_did_start_loading(url);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
set_resource(ResourceLoader::the().load_resource(Resource::Type::Generic, request));
|
||||||
|
|
||||||
if (type == Type::IFrame)
|
if (type == Type::IFrame)
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue