Use empty origin when only adjusting size

This commit is contained in:
Kevin Sawicki 2016-08-04 12:10:01 -07:00
parent 52199a008d
commit 7ae9c7616d

View file

@ -219,9 +219,7 @@ gfx::Point NativeWindow::GetPosition() {
} }
void NativeWindow::SetContentSize(const gfx::Size& size, bool animate) { void NativeWindow::SetContentSize(const gfx::Size& size, bool animate) {
gfx::Rect bounds = GetContentBounds(); SetSize(ContentBoundsToWindowBounds(gfx::Rect(size)).size(), animate);
bounds.set_size(size);
SetSize(ContentBoundsToWindowBounds(bounds).size(), animate);
} }
gfx::Size NativeWindow::GetContentSize() { gfx::Size NativeWindow::GetContentSize() {