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

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

Issue 2898743002: Draggable peeking/fullscreen launcher with transparent background. (Closed)
Patch Set: adressed comments. Created 3 years, 6 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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.h" 5 #include "ash/shelf/shelf.h"
6 6
7 #include "ash/public/cpp/config.h" 7 #include "ash/public/cpp/config.h"
8 #include "ash/public/cpp/shelf_item_delegate.h" 8 #include "ash/public/cpp/shelf_item_delegate.h"
9 #include "ash/public/cpp/shell_window_ids.h" 9 #include "ash/public/cpp/shell_window_ids.h"
10 #include "ash/root_window_controller.h" 10 #include "ash/root_window_controller.h"
(...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after
312 } 312 }
313 313
314 ShelfLockingManager* Shelf::GetShelfLockingManagerForTesting() { 314 ShelfLockingManager* Shelf::GetShelfLockingManagerForTesting() {
315 return &shelf_locking_manager_; 315 return &shelf_locking_manager_;
316 } 316 }
317 317
318 ShelfView* Shelf::GetShelfViewForTesting() { 318 ShelfView* Shelf::GetShelfViewForTesting() {
319 return shelf_widget_->shelf_view_for_testing(); 319 return shelf_widget_->shelf_view_for_testing();
320 } 320 }
321 321
322 void Shelf::OnAppListIsActive(bool hideBackground) {
323 shelf_layout_manager()->OnAppListIsActive(hideBackground);
324 }
325
322 void Shelf::WillDeleteShelfLayoutManager() { 326 void Shelf::WillDeleteShelfLayoutManager() {
323 if (Shell::GetAshConfig() == Config::MASH) { 327 if (Shell::GetAshConfig() == Config::MASH) {
324 // TODO(sky): this should be removed once Shell is used everywhere. 328 // TODO(sky): this should be removed once Shell is used everywhere.
325 ShutdownShelfWidget(); 329 ShutdownShelfWidget();
326 } 330 }
327 331
328 // Clear event handlers that might forward events to the destroyed instance. 332 // Clear event handlers that might forward events to the destroyed instance.
329 auto_hide_event_handler_.reset(); 333 auto_hide_event_handler_.reset();
330 bezel_event_handler_.reset(); 334 bezel_event_handler_.reset();
331 335
(...skipping 21 matching lines...) Expand all
353 357
354 void Shelf::OnBackgroundUpdated(ShelfBackgroundType background_type, 358 void Shelf::OnBackgroundUpdated(ShelfBackgroundType background_type,
355 AnimationChangeType change_type) { 359 AnimationChangeType change_type) {
356 if (background_type == GetBackgroundType()) 360 if (background_type == GetBackgroundType())
357 return; 361 return;
358 for (auto& observer : observers_) 362 for (auto& observer : observers_)
359 observer.OnBackgroundTypeChanged(background_type, change_type); 363 observer.OnBackgroundTypeChanged(background_type, change_type);
360 } 364 }
361 365
362 } // namespace ash 366 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698