diff --git a/atom/browser/native_window.cc b/atom/browser/native_window.cc index 3a3bc685b79c..be0d9789aa4b 100644 --- a/atom/browser/native_window.cc +++ b/atom/browser/native_window.cc @@ -219,9 +219,7 @@ gfx::Point NativeWindow::GetPosition() { } void NativeWindow::SetContentSize(const gfx::Size& size, bool animate) { - gfx::Rect bounds = GetContentBounds(); - bounds.set_size(size); - SetSize(ContentBoundsToWindowBounds(bounds).size(), animate); + SetSize(ContentBoundsToWindowBounds(gfx::Rect(size)).size(), animate); } gfx::Size NativeWindow::GetContentSize() {