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

Side by Side Diff: ash/root_window_controller.cc

Issue 2279533002: ash: Convert ShelfDelegate to use WmShelf* instead of Shelf* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: curlies 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 unified diff | Download patch
« no previous file with comments | « ash/mus/shell_delegate_mus.cc ('k') | ash/shelf/shelf_view_unittest.cc » ('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/root_window_controller.h" 5 #include "ash/root_window_controller.h"
6 6
7 #include <queue> 7 #include <queue>
8 #include <vector> 8 #include <vector>
9 9
10 #include "ash/aura/aura_layout_manager_adapter.h" 10 #include "ash/aura/aura_layout_manager_adapter.h"
(...skipping 460 matching lines...) Expand 10 before | Expand all | Expand 10 after
471 if (shelf_) 471 if (shelf_)
472 return; 472 return;
473 ShelfView* shelf_view = shelf_widget_->CreateShelfView(); 473 ShelfView* shelf_view = shelf_widget_->CreateShelfView();
474 474
475 shelf_.reset( 475 shelf_.reset(
476 new Shelf(wm_shelf_aura_.get(), shelf_view, shelf_widget_.get())); 476 new Shelf(wm_shelf_aura_.get(), shelf_view, shelf_widget_.get()));
477 shelf_widget_->set_shelf(shelf_.get()); 477 shelf_widget_->set_shelf(shelf_.get());
478 // Must be initialized before the delegate is notified because the delegate 478 // Must be initialized before the delegate is notified because the delegate
479 // may try to access the WmShelf. 479 // may try to access the WmShelf.
480 wm_shelf_aura_->SetShelf(shelf_.get()); 480 wm_shelf_aura_->SetShelf(shelf_.get());
481 WmShell::Get()->shelf_delegate()->OnShelfCreated(shelf_.get()); 481 WmShell::Get()->shelf_delegate()->OnShelfCreated(wm_shelf_aura_.get());
482 482
483 if (panel_layout_manager_) 483 if (panel_layout_manager_)
484 panel_layout_manager_->SetShelf(wm_shelf_aura_.get()); 484 panel_layout_manager_->SetShelf(wm_shelf_aura_.get());
485 if (docked_layout_manager_) { 485 if (docked_layout_manager_) {
486 docked_layout_manager_->SetShelf(wm_shelf_aura_.get()); 486 docked_layout_manager_->SetShelf(wm_shelf_aura_.get());
487 if (shelf_widget_->shelf_layout_manager()) 487 if (shelf_widget_->shelf_layout_manager())
488 docked_layout_manager_->AddObserver( 488 docked_layout_manager_->AddObserver(
489 shelf_widget_->shelf_layout_manager()); 489 shelf_widget_->shelf_layout_manager());
490 } 490 }
491 491
(...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after
959 aura::Window* primary_root_window = Shell::GetInstance() 959 aura::Window* primary_root_window = Shell::GetInstance()
960 ->window_tree_host_manager() 960 ->window_tree_host_manager()
961 ->GetPrimaryRootWindow(); 961 ->GetPrimaryRootWindow();
962 return GetRootWindowSettings(primary_root_window)->controller; 962 return GetRootWindowSettings(primary_root_window)->controller;
963 } 963 }
964 964
965 return GetRootWindowSettings(root_window)->controller; 965 return GetRootWindowSettings(root_window)->controller;
966 } 966 }
967 967
968 } // namespace ash 968 } // namespace ash
OLDNEW
« no previous file with comments | « ash/mus/shell_delegate_mus.cc ('k') | ash/shelf/shelf_view_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698