mirror of
https://github.com/lightpanda-io/browser.git
synced 2025-10-29 15:13:28 +00:00
send attach events before result
This commit is contained in:
committed by
Pierre Tachoire
parent
a3e2b5246e
commit
fbb0e675f5
@@ -134,10 +134,6 @@ fn createTarget(cmd: anytype) !void {
|
|||||||
);
|
);
|
||||||
try page.start(aux_data);
|
try page.start(aux_data);
|
||||||
|
|
||||||
try cmd.sendResult(.{
|
|
||||||
.targetId = target_id,
|
|
||||||
}, .{});
|
|
||||||
|
|
||||||
// send targetCreated event
|
// send targetCreated event
|
||||||
// TODO: should this only be sent when Target.setDiscoverTargets
|
// TODO: should this only be sent when Target.setDiscoverTargets
|
||||||
// has been enabled?
|
// has been enabled?
|
||||||
@@ -154,6 +150,10 @@ fn createTarget(cmd: anytype) !void {
|
|||||||
// only if setAutoAttach is true?
|
// only if setAutoAttach is true?
|
||||||
try doAttachtoTarget(cmd, target_id);
|
try doAttachtoTarget(cmd, target_id);
|
||||||
bc.target_id = target_id;
|
bc.target_id = target_id;
|
||||||
|
|
||||||
|
try cmd.sendResult(.{
|
||||||
|
.targetId = target_id,
|
||||||
|
}, .{});
|
||||||
}
|
}
|
||||||
|
|
||||||
fn attachToTarget(cmd: anytype) !void {
|
fn attachToTarget(cmd: anytype) !void {
|
||||||
|
|||||||
Reference in New Issue
Block a user