| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/ui/views/frame/contents_layout_manager.h" | 5 #include "chrome/browser/ui/views/frame/contents_layout_manager.h" |
| 6 | 6 |
| 7 #include "ui/views/view.h" | 7 #include "ui/views/view.h" |
| 8 | 8 |
| 9 ContentsLayoutManager::ContentsLayoutManager( | 9 ContentsLayoutManager::ContentsLayoutManager( |
| 10 views::View* devtools_view, | 10 views::View* devtools_view, |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 ApplyDevToolsContentsResizingStrategy(strategy_, container_size, | 55 ApplyDevToolsContentsResizingStrategy(strategy_, container_size, |
| 56 old_devtools_bounds, old_contents_bounds, | 56 old_devtools_bounds, old_contents_bounds, |
| 57 &new_devtools_bounds, &new_contents_bounds); | 57 &new_devtools_bounds, &new_contents_bounds); |
| 58 new_devtools_bounds.Offset(0, top); | 58 new_devtools_bounds.Offset(0, top); |
| 59 new_contents_bounds.Offset(0, top); | 59 new_contents_bounds.Offset(0, top); |
| 60 | 60 |
| 61 devtools_view_->SetBoundsRect(new_devtools_bounds); | 61 devtools_view_->SetBoundsRect(new_devtools_bounds); |
| 62 contents_view_->SetBoundsRect(new_contents_bounds); | 62 contents_view_->SetBoundsRect(new_contents_bounds); |
| 63 } | 63 } |
| 64 | 64 |
| 65 gfx::Size ContentsLayoutManager::GetPreferredSize(views::View* host) { | 65 gfx::Size ContentsLayoutManager::GetPreferredSize( |
| 66 const views::View* host) const { |
| 66 return gfx::Size(); | 67 return gfx::Size(); |
| 67 } | 68 } |
| 68 | 69 |
| 69 void ContentsLayoutManager::Installed(views::View* host) { | 70 void ContentsLayoutManager::Installed(views::View* host) { |
| 70 DCHECK(!host_); | 71 DCHECK(!host_); |
| 71 host_ = host; | 72 host_ = host; |
| 72 } | 73 } |
| 73 | 74 |
| 74 void ContentsLayoutManager::Uninstalled(views::View* host) { | 75 void ContentsLayoutManager::Uninstalled(views::View* host) { |
| 75 DCHECK(host_ == host); | 76 DCHECK(host_ == host); |
| 76 host_ = NULL; | 77 host_ = NULL; |
| 77 } | 78 } |
| OLD | NEW |