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

Side by Side Diff: ash/shelf/shelf_layout_manager.cc

Issue 1929023002: Refactors WindowResizers to use ash/wm/common (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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
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/shelf/shelf_layout_manager.h" 5 #include "ash/shelf/shelf_layout_manager.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cmath> 8 #include <cmath>
9 #include <cstring> 9 #include <cstring>
10 #include <string> 10 #include <string>
11 #include <vector> 11 #include <vector>
12 12
13 #include "ash/accelerators/accelerator_commands.h" 13 #include "ash/accelerators/accelerator_commands.h"
14 #include "ash/ash_switches.h" 14 #include "ash/ash_switches.h"
15 #include "ash/root_window_controller.h" 15 #include "ash/root_window_controller.h"
16 #include "ash/screen_util.h" 16 #include "ash/screen_util.h"
17 #include "ash/session/session_state_delegate.h" 17 #include "ash/session/session_state_delegate.h"
18 #include "ash/shelf/shelf.h" 18 #include "ash/shelf/shelf.h"
19 #include "ash/shelf/shelf_bezel_event_filter.h" 19 #include "ash/shelf/shelf_bezel_event_filter.h"
20 #include "ash/shelf/shelf_constants.h" 20 #include "ash/shelf/shelf_constants.h"
21 #include "ash/shelf/shelf_layout_manager_observer.h" 21 #include "ash/shelf/shelf_layout_manager_observer.h"
22 #include "ash/shelf/shelf_util.h" 22 #include "ash/shelf/shelf_util.h"
23 #include "ash/shelf/shelf_widget.h" 23 #include "ash/shelf/shelf_widget.h"
24 #include "ash/shell.h" 24 #include "ash/shell.h"
25 #include "ash/shell_window_ids.h" 25 #include "ash/shell_window_ids.h"
26 #include "ash/system/status_area_widget.h" 26 #include "ash/system/status_area_widget.h"
27 #include "ash/wm/aura/wm_window_aura.h" 27 #include "ash/wm/aura/wm_window_aura.h"
28 #include "ash/wm/common/shelf/wm_shelf_util.h"
28 #include "ash/wm/common/window_state.h" 29 #include "ash/wm/common/window_state.h"
29 #include "ash/wm/common/wm_root_window_controller.h" 30 #include "ash/wm/common/wm_root_window_controller.h"
30 #include "ash/wm/common/wm_root_window_controller_observer.h" 31 #include "ash/wm/common/wm_root_window_controller_observer.h"
31 #include "ash/wm/gestures/shelf_gesture_handler.h" 32 #include "ash/wm/gestures/shelf_gesture_handler.h"
32 #include "ash/wm/lock_state_controller.h" 33 #include "ash/wm/lock_state_controller.h"
33 #include "ash/wm/mru_window_tracker.h" 34 #include "ash/wm/mru_window_tracker.h"
34 #include "ash/wm/window_animations.h" 35 #include "ash/wm/window_animations.h"
35 #include "ash/wm/window_state_aura.h" 36 #include "ash/wm/window_state_aura.h"
36 #include "ash/wm/window_util.h" 37 #include "ash/wm/window_util.h"
37 #include "ash/wm/workspace_controller.h" 38 #include "ash/wm/workspace_controller.h"
(...skipping 483 matching lines...) Expand 10 before | Expand all | Expand 10 after
521 } 522 }
522 523
523 void ShelfLayoutManager::OnWindowActivated( 524 void ShelfLayoutManager::OnWindowActivated(
524 aura::client::ActivationChangeObserver::ActivationReason reason, 525 aura::client::ActivationChangeObserver::ActivationReason reason,
525 aura::Window* gained_active, 526 aura::Window* gained_active,
526 aura::Window* lost_active) { 527 aura::Window* lost_active) {
527 UpdateAutoHideStateNow(); 528 UpdateAutoHideStateNow();
528 } 529 }
529 530
530 bool ShelfLayoutManager::IsHorizontalAlignment() const { 531 bool ShelfLayoutManager::IsHorizontalAlignment() const {
531 return ash::IsHorizontalAlignment(GetAlignment()); 532 return wm::IsHorizontalAlignment(GetAlignment());
532 } 533 }
533 534
534 void ShelfLayoutManager::SetChromeVoxPanelHeight(int height) { 535 void ShelfLayoutManager::SetChromeVoxPanelHeight(int height) {
535 chromevox_panel_height_ = height; 536 chromevox_panel_height_ = height;
536 LayoutShelf(); 537 LayoutShelf();
537 } 538 }
538 539
539 //////////////////////////////////////////////////////////////////////////////// 540 ////////////////////////////////////////////////////////////////////////////////
540 // ShelfLayoutManager, private: 541 // ShelfLayoutManager, private:
541 542
(...skipping 593 matching lines...) Expand 10 before | Expand all | Expand 10 after
1135 UpdateBoundsAndOpacity(target_bounds, true, NULL); 1136 UpdateBoundsAndOpacity(target_bounds, true, NULL);
1136 UpdateVisibilityState(); 1137 UpdateVisibilityState();
1137 } 1138 }
1138 1139
1139 void ShelfLayoutManager::UpdateShelfVisibilityAfterLoginUIChange() { 1140 void ShelfLayoutManager::UpdateShelfVisibilityAfterLoginUIChange() {
1140 UpdateVisibilityState(); 1141 UpdateVisibilityState();
1141 LayoutShelf(); 1142 LayoutShelf();
1142 } 1143 }
1143 1144
1144 } // namespace ash 1145 } // namespace ash
OLDNEW
« no previous file with comments | « ash/shelf/shelf.cc ('k') | ash/shelf/shelf_types.h » ('j') | ash/wm/common/wm_globals.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698