Move Notification from App to BrowserContext

This commit is contained in:
Nikolay Govorov
2026-02-03 17:02:09 +00:00
parent dbf18b90a7
commit fd8c488dbd
14 changed files with 130 additions and 119 deletions

View File

@@ -27,7 +27,6 @@ const Telemetry = @import("telemetry/telemetry.zig").Telemetry;
pub const Http = @import("http/Http.zig");
pub const ArenaPool = @import("ArenaPool.zig");
pub const Notification = @import("Notification.zig");
// Container for global state / objects that various parts of the system
// might need.
@@ -41,7 +40,6 @@ telemetry: Telemetry,
allocator: Allocator,
arena_pool: ArenaPool,
app_dir_path: ?[]const u8,
notification: *Notification,
shutdown: bool = false,
pub const RunMode = enum {
@@ -70,9 +68,6 @@ pub fn init(allocator: Allocator, config: Config) !*App {
app.config = config;
app.allocator = allocator;
app.notification = try Notification.init(allocator);
errdefer app.notification.deinit();
app.http = try Http.init(allocator, .{
.max_host_open = config.http_max_host_open orelse 4,
.max_concurrent = config.http_max_concurrent orelse 10,
@@ -113,7 +108,6 @@ pub fn deinit(self: *App) void {
self.app_dir_path = null;
}
self.telemetry.deinit();
self.notification.deinit();
self.http.deinit();
self.snapshot.deinit();
self.platform.deinit();