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

Unified Diff: ash/shelf/shelf_widget.h

Issue 2191363002: Reland of "Apply Shelf/Dock opacity animations for the Material Design style." (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added ShelfBackgoundAnimator::Initialize(ShelfBackgroundAnimatorObserver*). 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/shelf/shelf_view_unittest.cc ('k') | ash/shelf/shelf_widget.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/shelf/shelf_widget.h
diff --git a/ash/shelf/shelf_widget.h b/ash/shelf/shelf_widget.h
index af6de3defeb81d3fd61485a5edb71f769c09d5db..0add03862b06bf26f0322b3a439801faf0181eec 100644
--- a/ash/shelf/shelf_widget.h
+++ b/ash/shelf/shelf_widget.h
@@ -8,8 +8,9 @@
#include <memory>
#include "ash/ash_export.h"
+#include "ash/common/shelf/shelf_background_animator.h"
+#include "ash/common/shelf/shelf_background_animator_observer.h"
#include "ash/common/shelf/shelf_types.h"
-#include "ash/common/wm/background_animator.h"
#include "ash/shelf/shelf_layout_manager_observer.h"
#include "base/macros.h"
#include "ui/views/widget/widget.h"
@@ -26,6 +27,7 @@ class WorkspaceController;
class ASH_EXPORT ShelfWidget : public views::Widget,
public views::WidgetObserver,
+ public ShelfBackgroundAnimatorObserver,
public ShelfLayoutManagerObserver {
public:
ShelfWidget(WmWindow* wm_shelf_container,
@@ -59,7 +61,7 @@ class ASH_EXPORT ShelfWidget : public views::Widget,
Shelf* shelf() const { return shelf_.get(); }
StatusAreaWidget* status_area_widget() const { return status_area_widget_; }
- void CreateShelf(WmShelfAura* wm_shelf_aura);
+ void CreateShelf();
void PostCreateShelf();
// Set visibility of the shelf.
@@ -94,6 +96,9 @@ class ASH_EXPORT ShelfWidget : public views::Widget,
// Disable dimming animations for running tests.
void DisableDimmingAnimationsForTest();
+ // ShelfBackgroundAnimatorObserver overrides:
+ void UpdateShelfItemBackground(int alpha) override;
+
// ShelfLayoutManagerObserver overrides:
void WillDeleteShelfLayoutManager() override;
@@ -104,6 +109,8 @@ class ASH_EXPORT ShelfWidget : public views::Widget,
void OnMouseEvent(ui::MouseEvent* event) override;
void OnGestureEvent(ui::GestureEvent* event) override;
+ WmShelfAura* wm_shelf_aura_;
+
// Owned by the shelf container's aura::Window.
ShelfLayoutManager* shelf_layout_manager_;
std::unique_ptr<Shelf> shelf_;
@@ -112,7 +119,7 @@ class ASH_EXPORT ShelfWidget : public views::Widget,
// |delegate_view_| is the contents view of this widget and is cleaned up
// during CloseChildWindows of the associated RootWindowController.
DelegateView* delegate_view_;
- BackgroundAnimator background_animator_;
+ ShelfBackgroundAnimator background_animator_;
bool activating_as_fallback_;
DISALLOW_COPY_AND_ASSIGN(ShelfWidget);
« no previous file with comments | « ash/shelf/shelf_view_unittest.cc ('k') | ash/shelf/shelf_widget.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698