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

Side by Side Diff: ash/wm/workspace_controller.cc

Issue 10857021: Prepare a bunch of ash tests for workspace2. With Workspace2 you can't (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 4 months 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "ash/wm/workspace_controller.h" 5 #include "ash/wm/workspace_controller.h"
6 6
7 #include "ash/wm/window_util.h" 7 #include "ash/wm/window_util.h"
8 #include "ash/wm/workspace/workspace_event_filter.h" 8 #include "ash/wm/workspace/workspace_event_filter.h"
9 #include "ash/wm/workspace/workspace_layout_manager.h" 9 #include "ash/wm/workspace/workspace_layout_manager.h"
10 #include "ash/wm/workspace/workspace_manager.h" 10 #include "ash/wm/workspace/workspace_manager.h"
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 // WorkspaceLayoutManager may attempt to access state from us. Destroy it now. 44 // WorkspaceLayoutManager may attempt to access state from us. Destroy it now.
45 if (viewport_->layout_manager() == layout_manager_) 45 if (viewport_->layout_manager() == layout_manager_)
46 viewport_->SetLayoutManager(NULL); 46 viewport_->SetLayoutManager(NULL);
47 } 47 }
48 48
49 bool WorkspaceController::IsInMaximizedMode() const { 49 bool WorkspaceController::IsInMaximizedMode() const {
50 return workspace_manager_->IsInMaximizedMode(); 50 return workspace_manager_->IsInMaximizedMode();
51 } 51 }
52 52
53 void WorkspaceController::SetGridSize(int grid_size) { 53 void WorkspaceController::SetGridSize(int grid_size) {
54 workspace_manager_->set_grid_size(grid_size); 54 workspace_manager_->SetGridSize(grid_size);
55 event_filter_->set_grid_size(grid_size); 55 event_filter_->set_grid_size(grid_size);
56 } 56 }
57 57
58 int WorkspaceController::GetGridSize() const { 58 int WorkspaceController::GetGridSize() const {
59 return workspace_manager_->grid_size(); 59 return workspace_manager_->grid_size();
60 } 60 }
61 61
62 WorkspaceWindowState WorkspaceController::GetWindowState() const { 62 WorkspaceWindowState WorkspaceController::GetWindowState() const {
63 return workspace_manager_->GetWindowState(); 63 return workspace_manager_->GetWindowState();
64 } 64 }
65 65
66 void WorkspaceController::SetShelf(ShelfLayoutManager* shelf) { 66 void WorkspaceController::SetShelf(ShelfLayoutManager* shelf) {
67 workspace_manager_->set_shelf(shelf); 67 workspace_manager_->set_shelf(shelf);
68 } 68 }
69 69
70 void WorkspaceController::OnWindowActivated(aura::Window* window, 70 void WorkspaceController::OnWindowActivated(aura::Window* window,
71 aura::Window* old_active) { 71 aura::Window* old_active) {
72 workspace_manager_->SetActiveWorkspaceByWindow(window); 72 workspace_manager_->SetActiveWorkspaceByWindow(window);
73 } 73 }
74 74
75 } // namespace internal 75 } // namespace internal
76 } // namespace ash 76 } // namespace ash
OLDNEW
« no previous file with comments | « ash/wm/workspace/workspace_window_resizer_unittest.cc ('k') | ash/wm/workspace_controller_test_helper.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698