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

Unified Diff: ash/common/shelf/shelf_layout_manager.cc

Issue 2293183002: ash: Remove ash::Shelf in favor of ash::WmShelf (Closed)
Patch Set: rebase again Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ash/common/shelf/shelf_button_pressed_metric_tracker_unittest.cc ('k') | ash/common/shelf/shelf_widget.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/common/shelf/shelf_layout_manager.cc
diff --git a/ash/common/shelf/shelf_layout_manager.cc b/ash/common/shelf/shelf_layout_manager.cc
index eb25188a57740c3bd8bb68986b69131f2f9fb495..6761f97ac4325969a19b817b38fde3adae7771c7 100644
--- a/ash/common/shelf/shelf_layout_manager.cc
+++ b/ash/common/shelf/shelf_layout_manager.cc
@@ -240,7 +240,7 @@ void ShelfLayoutManager::UpdateVisibilityState() {
WmWindow* shelf_window = WmLookup::Get()->GetWindowForWidget(shelf_widget_);
WmRootWindowController* controller = shelf_window->GetRootWindowController();
// Bail out early before the shelf is initialized or after it is destroyed.
- if (!controller || !shelf_widget_->shelf() || in_shutdown_)
+ if (!controller || !wm_shelf_->IsShelfInitialized() || in_shutdown_)
return;
bool was_invisible_auto_hide_shelf = invisible_auto_hide_shelf_;
// Always reset to be safe.
@@ -888,7 +888,7 @@ gfx::Rect ShelfLayoutManager::GetAutoHideShowShelfRegionInScreen() const {
ShelfAutoHideState ShelfLayoutManager::CalculateAutoHideState(
ShelfVisibilityState visibility_state) const {
- if (visibility_state != SHELF_AUTO_HIDE || !shelf_widget_->shelf())
+ if (visibility_state != SHELF_AUTO_HIDE || !wm_shelf_->IsShelfInitialized())
return SHELF_AUTO_HIDE_HIDDEN;
const int64_t shelf_display_id = WmLookup::Get()
« no previous file with comments | « ash/common/shelf/shelf_button_pressed_metric_tracker_unittest.cc ('k') | ash/common/shelf/shelf_widget.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698