Need a Linux impl for https://github.com/electron/electron/pull/12485
atom/browser/api/atom_api_top_level_window.cc
if (Emit("close")) {
    *prevent_default = true;
  }
}
void TopLevelWindow::OnWindowClosed() {
  
  
  
  weak_factory_.InvalidateWeakPtrs();
  RemoveFromWeakMap();
  window_->RemoveObserver(this);
  
  
  MarkDestroyed();
  Emit("closed");
  RemoveFromParentChildWindows();
  TopLevelWindow::ResetBrowserViews();
  
  base::ThreadTaskRunnerHandle::Get()->PostTask(FROM_HERE, GetDestroyClosure());
}
void TopLevelWindow::OnWindowEndSession() {