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

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

Issue 2000393003: ash: Reorder shutdown of ShelfLayoutManager and StatusAreaWidget (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase 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
« no previous file with comments | « ash/root_window_controller.cc ('k') | ash/shelf/shelf_layout_manager_observer.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) 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>
(...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after
241 } 241 }
242 Shell::GetInstance()->lock_state_controller()->AddObserver(this); 242 Shell::GetInstance()->lock_state_controller()->AddObserver(this);
243 aura::client::GetActivationClient(root_window_)->AddObserver(this); 243 aura::client::GetActivationClient(root_window_)->AddObserver(this);
244 Shell::GetInstance()->session_state_delegate()->AddSessionStateObserver(this); 244 Shell::GetInstance()->session_state_delegate()->AddSessionStateObserver(this);
245 } 245 }
246 246
247 ShelfLayoutManager::~ShelfLayoutManager() { 247 ShelfLayoutManager::~ShelfLayoutManager() {
248 if (update_shelf_observer_) 248 if (update_shelf_observer_)
249 update_shelf_observer_->Detach(); 249 update_shelf_observer_->Detach();
250 250
251 FOR_EACH_OBSERVER(ShelfLayoutManagerObserver, observers_, WillDeleteShelf()); 251 FOR_EACH_OBSERVER(ShelfLayoutManagerObserver, observers_,
252 WillDeleteShelfLayoutManager());
252 Shell::GetInstance()->RemoveShellObserver(this); 253 Shell::GetInstance()->RemoveShellObserver(this);
253 Shell::GetInstance()->lock_state_controller()->RemoveObserver(this); 254 Shell::GetInstance()->lock_state_controller()->RemoveObserver(this);
254 Shell::GetInstance()-> 255 Shell::GetInstance()->
255 session_state_delegate()->RemoveSessionStateObserver(this); 256 session_state_delegate()->RemoveSessionStateObserver(this);
256 if (root_window_controller_observer_) { 257 if (root_window_controller_observer_) {
257 wm::WmWindowAura::Get(root_window_) 258 wm::WmWindowAura::Get(root_window_)
258 ->GetRootWindowController() 259 ->GetRootWindowController()
259 ->RemoveObserver(root_window_controller_observer_.get()); 260 ->RemoveObserver(root_window_controller_observer_.get());
260 } 261 }
261 } 262 }
(...skipping 883 matching lines...) Expand 10 before | Expand all | Expand 10 after
1145 UpdateBoundsAndOpacity(target_bounds, true, NULL); 1146 UpdateBoundsAndOpacity(target_bounds, true, NULL);
1146 UpdateVisibilityState(); 1147 UpdateVisibilityState();
1147 } 1148 }
1148 1149
1149 void ShelfLayoutManager::UpdateShelfVisibilityAfterLoginUIChange() { 1150 void ShelfLayoutManager::UpdateShelfVisibilityAfterLoginUIChange() {
1150 UpdateVisibilityState(); 1151 UpdateVisibilityState();
1151 LayoutShelf(); 1152 LayoutShelf();
1152 } 1153 }
1153 1154
1154 } // namespace ash 1155 } // namespace ash
OLDNEW
« no previous file with comments | « ash/root_window_controller.cc ('k') | ash/shelf/shelf_layout_manager_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698