diff --git a/atom/browser/native_window_mac.mm b/atom/browser/native_window_mac.mm index 39576c04e7f1..ca70e93f3703 100644 --- a/atom/browser/native_window_mac.mm +++ b/atom/browser/native_window_mac.mm @@ -576,7 +576,12 @@ void NativeWindowMac::Hide() { } bool NativeWindowMac::IsVisible() { - return [window_ isVisible]; + bool occluded = [window_ occlusionState] == NSWindowOcclusionStateVisible; + + // For a window to be visible, it must be visible to the user in the + // foreground of the app, which means that it should not be minimized or + // occluded + return [window_ isVisible] && !occluded && !IsMinimized(); } bool NativeWindowMac::IsEnabled() {