mirror of
https://github.com/lightpanda-io/browser.git
synced 2026-03-22 04:34:44 +00:00
Merge pull request #1686 from lightpanda-io/load_event_iframe_fix
Fix load event for page with no external scripts but with iframes
This commit is contained in:
@@ -866,11 +866,6 @@ fn pageDoneCallback(ctx: *anyopaque) !void {
|
||||
.html => |buf| {
|
||||
parser.parse(buf.items);
|
||||
self._script_manager.staticScriptsDone();
|
||||
if (self._script_manager.isDone()) {
|
||||
// No scripts, or just inline scripts that were already processed
|
||||
// we need to trigger this ourselves
|
||||
self.documentIsComplete();
|
||||
}
|
||||
self._parse_state = .complete;
|
||||
},
|
||||
.text => |*buf| {
|
||||
|
||||
@@ -582,12 +582,6 @@ fn evaluate(self: *ScriptManager) void {
|
||||
}
|
||||
}
|
||||
|
||||
pub fn isDone(self: *const ScriptManager) bool {
|
||||
return self.static_scripts_done and // page is done processing initial html
|
||||
self.defer_scripts.first == null and // no deferred scripts
|
||||
self.async_scripts.first == null; // no async scripts
|
||||
}
|
||||
|
||||
fn parseImportmap(self: *ScriptManager, script: *const Script) !void {
|
||||
const content = script.source.content();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user