mirror of
https://github.com/lightpanda-io/browser.git
synced 2025-12-19 10:28:10 +00:00
Merge pull request #1253 from lightpanda-io/zigdom-navigation
Backport Navigation (and friends)
This commit is contained in:
@@ -183,7 +183,7 @@ fn navigate(cmd: anytype) !void {
|
||||
try page.navigate(params.url, .{
|
||||
.reason = .address_bar,
|
||||
.cdp_id = cmd.input.id,
|
||||
});
|
||||
}, .{ .push = null });
|
||||
}
|
||||
|
||||
pub fn pageNavigate(arena: Allocator, bc: anytype, event: *const Notification.PageNavigate) !void {
|
||||
@@ -206,7 +206,7 @@ pub fn pageNavigate(arena: Allocator, bc: anytype, event: *const Notification.Pa
|
||||
.POST => "formSubmissionPost",
|
||||
else => unreachable,
|
||||
},
|
||||
.address_bar => null,
|
||||
.address_bar, .navigation => null,
|
||||
};
|
||||
if (reason_) |reason| {
|
||||
try cdp.sendEvent("Page.frameScheduledNavigation", .{
|
||||
|
||||
@@ -179,9 +179,11 @@ fn createTarget(cmd: anytype) !void {
|
||||
try doAttachtoTarget(cmd, target_id);
|
||||
}
|
||||
|
||||
try page.navigate(params.url, .{
|
||||
.reason = .address_bar,
|
||||
});
|
||||
try page.navigate(
|
||||
params.url,
|
||||
.{ .reason = .address_bar },
|
||||
.{ .push = null },
|
||||
);
|
||||
|
||||
try cmd.sendResult(.{
|
||||
.targetId = target_id,
|
||||
|
||||
Reference in New Issue
Block a user