diff --git a/lib/overrides/Gtk-3.0.js b/lib/overrides/Gtk-3.0.js index eed86b2..fec91e5 100644 --- a/lib/overrides/Gtk-3.0.js +++ b/lib/overrides/Gtk-3.0.js @@ -32,6 +32,14 @@ exports.apply = (Gtk) => { process._tickCallback() const loopStack = internal.GetLoopStack() + + /* + * To keep the nodejs event loop alive, we need to have something running. + */ + if (placeholderIntervalID === undefined) { + placeholderIntervalID = setInterval(() => { /* noop */ }, 60 * 60 * 1000) + } + loopStack.push(originalQuit) originalMain()