OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "ui/aura_shell/root_window_layout_manager.h" | 5 #include "ui/aura_shell/root_window_layout_manager.h" |
6 | 6 |
7 #include "ui/aura/window.h" | 7 #include "ui/aura/window.h" |
8 #include "ui/views/widget/widget.h" | 8 #include "ui/views/widget/widget.h" |
9 | 9 |
10 namespace aura_shell { | 10 namespace aura_shell { |
(...skipping 14 matching lines...) Expand all Loading... |
25 // RootWindowLayoutManager, aura::LayoutManager implementation: | 25 // RootWindowLayoutManager, aura::LayoutManager implementation: |
26 | 26 |
27 void RootWindowLayoutManager::OnWindowResized() { | 27 void RootWindowLayoutManager::OnWindowResized() { |
28 gfx::Rect fullscreen_bounds = | 28 gfx::Rect fullscreen_bounds = |
29 gfx::Rect(owner_->bounds().width(), owner_->bounds().height()); | 29 gfx::Rect(owner_->bounds().width(), owner_->bounds().height()); |
30 | 30 |
31 aura::Window::Windows::const_iterator i; | 31 aura::Window::Windows::const_iterator i; |
32 for (i = owner_->children().begin(); i != owner_->children().end(); ++i) | 32 for (i = owner_->children().begin(); i != owner_->children().end(); ++i) |
33 (*i)->SetBounds(fullscreen_bounds); | 33 (*i)->SetBounds(fullscreen_bounds); |
34 | 34 |
35 background_widget_->SetBounds(fullscreen_bounds); | 35 if (background_widget_) |
| 36 background_widget_->SetBounds(fullscreen_bounds); |
36 } | 37 } |
37 | 38 |
38 void RootWindowLayoutManager::OnWindowAddedToLayout(aura::Window* child) { | 39 void RootWindowLayoutManager::OnWindowAddedToLayout(aura::Window* child) { |
39 } | 40 } |
40 | 41 |
41 void RootWindowLayoutManager::OnWillRemoveWindowFromLayout( | 42 void RootWindowLayoutManager::OnWillRemoveWindowFromLayout( |
42 aura::Window* child) { | 43 aura::Window* child) { |
43 } | 44 } |
44 | 45 |
45 void RootWindowLayoutManager::OnChildWindowVisibilityChanged( | 46 void RootWindowLayoutManager::OnChildWindowVisibilityChanged( |
46 aura::Window* child, | 47 aura::Window* child, |
47 bool visible) { | 48 bool visible) { |
48 } | 49 } |
49 | 50 |
50 void RootWindowLayoutManager::SetChildBounds( | 51 void RootWindowLayoutManager::SetChildBounds( |
51 aura::Window* child, | 52 aura::Window* child, |
52 const gfx::Rect& requested_bounds) { | 53 const gfx::Rect& requested_bounds) { |
53 SetChildBoundsDirect(child, requested_bounds); | 54 SetChildBoundsDirect(child, requested_bounds); |
54 } | 55 } |
55 | 56 |
56 } // namespace internal | 57 } // namespace internal |
57 } // namespace aura_shell | 58 } // namespace aura_shell |
OLD | NEW |