Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(631)

Side by Side Diff: ui/aura_shell/root_window_layout_manager.cc

Issue 8895003: Aura: Add --aura-laptop-mode to fill the workspace with a single window. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase, fix unit test build Created 9 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ui/aura_shell/root_window_layout_manager.h ('k') | ui/aura_shell/shelf_layout_manager.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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
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
OLDNEW
« no previous file with comments | « ui/aura_shell/root_window_layout_manager.h ('k') | ui/aura_shell/shelf_layout_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698