From 00358545a9098158f095f47013483e83bb3b35d0 Mon Sep 17 00:00:00 2001 From: Shelley Vohr Date: Tue, 30 Apr 2019 16:43:45 -0700 Subject: [PATCH] fix: explicitly focus window on win.show() (#18046) --- atom/browser/native_window_views.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/atom/browser/native_window_views.cc b/atom/browser/native_window_views.cc index 2bf425ba91..305583c94d 100644 --- a/atom/browser/native_window_views.cc +++ b/atom/browser/native_window_views.cc @@ -380,6 +380,9 @@ void NativeWindowViews::Show() { widget()->native_widget_private()->Show(GetRestoredState(), gfx::Rect()); + // explicitly focus the window + widget()->Activate(); + NotifyWindowShow(); #if defined(USE_X11)