Merge branch 'master' into roller/chromium/master

This commit is contained in:
John Kleinschmidt 2021-03-15 18:43:25 -04:00
parent 8f4e362d8f
commit 57a8781c01
137 changed files with 876 additions and 4289 deletions

View file

@ -114,8 +114,7 @@ BaseWindow::BaseWindow(gin_helper::Arguments* args,
}
BaseWindow::~BaseWindow() {
if (!window_->IsClosed())
window_->CloseImmediately();
CloseImmediately();
// Destroy the native window in next tick because the native code might be
// iterating all windows.
@ -318,6 +317,11 @@ void BaseWindow::SetContentView(gin::Handle<View> view) {
window_->SetContentView(view->view());
}
void BaseWindow::CloseImmediately() {
if (!window_->IsClosed())
window_->CloseImmediately();
}
void BaseWindow::Close() {
window_->Close();
}