diff --git a/atom/browser/native_window_mac.mm b/atom/browser/native_window_mac.mm index dc2929f82ec..c35c177ac29 100644 --- a/atom/browser/native_window_mac.mm +++ b/atom/browser/native_window_mac.mm @@ -244,7 +244,8 @@ bool ScopedDisableResize::disable_resize_ = false; } - (NSRect)window:(NSWindow *)window willPositionSheet:(NSWindow *)sheet usingRect:(NSRect)rect { - rect.origin.y = window.contentView.frame.size.height - shell_->GetSheetOffset(); + NSView * view = window.contentView; + rect.origin.y = view.frame.size.height - shell_->GetSheetOffset(); return rect; }