Chromium Code Reviews| Index: ui/aura/window.cc |
| diff --git a/ui/aura/window.cc b/ui/aura/window.cc |
| index cd4debe82cbc0b6043efc244e7d9852e3d86aace..ede3831c4b83869d38b696d45d46de0246136bb8 100644 |
| --- a/ui/aura/window.cc |
| +++ b/ui/aura/window.cc |
| @@ -293,19 +293,15 @@ std::unique_ptr<ui::EventTargeter> Window::SetEventTargeter( |
| } |
| void Window::SetBounds(const gfx::Rect& new_bounds) { |
| - if (parent_ && parent_->layout_manager()) |
|
mfomitchev
2016/12/08 20:44:23
Please put this back
|
| - parent_->layout_manager()->SetChildBounds(this, new_bounds); |
| - else { |
| - // Ensure we don't go smaller than our minimum bounds. |
| - gfx::Rect final_bounds(new_bounds); |
| - if (delegate_) { |
| - const gfx::Size& min_size = delegate_->GetMinimumSize(); |
| - final_bounds.set_width(std::max(min_size.width(), final_bounds.width())); |
| - final_bounds.set_height(std::max(min_size.height(), |
| - final_bounds.height())); |
| - } |
| - SetBoundsInternal(final_bounds); |
| + // Ensure we don't go smaller than our minimum bounds. |
| + gfx::Rect final_bounds(new_bounds); |
| + if (delegate_) { |
| + const gfx::Size& min_size = delegate_->GetMinimumSize(); |
| + final_bounds.set_width(std::max(min_size.width(), final_bounds.width())); |
| + final_bounds.set_height(std::max(min_size.height(), |
| + final_bounds.height())); |
| } |
| + SetBoundsInternal(final_bounds); |
| } |
| void Window::SetBoundsInScreen(const gfx::Rect& new_bounds_in_screen, |