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

Unified Diff: ash/shelf/shelf_bezel_event_handler.h

Issue 2237613002: mash: Migrate some misc ShelfLayoutManager deps to ash common. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Move ShelfBezelEventHandler to WmShelfAura. 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
Index: ash/shelf/shelf_bezel_event_handler.h
diff --git a/ash/shelf/shelf_bezel_event_filter.h b/ash/shelf/shelf_bezel_event_handler.h
similarity index 50%
rename from ash/shelf/shelf_bezel_event_filter.h
rename to ash/shelf/shelf_bezel_event_handler.h
index ff7d14d034512bf54b17b35569edaff4c529507f..e46550e307a44878d657794fcfe9d46cae1e9702 100644
--- a/ash/shelf/shelf_bezel_event_filter.h
+++ b/ash/shelf/shelf_bezel_event_handler.h
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef ASH_SHELF_SHELF_BEZEL_EVENT_FILTER_H_
-#define ASH_SHELF_SHELF_BEZEL_EVENT_FILTER_H_
+#ifndef ASH_SHELF_SHELF_BEZEL_EVENT_HANDLER_H_
+#define ASH_SHELF_SHELF_BEZEL_EVENT_HANDLER_H_
#include "base/macros.h"
#include "ui/events/event_handler.h"
@@ -14,14 +14,13 @@ class Rect;
}
namespace ash {
-class ShelfLayoutManager;
+class WmShelf;
-// Detects and forwards touch gestures that occur on a bezel sensor to the
-// shelf.
-class ShelfBezelEventFilter : public ui::EventHandler {
+// Forwards touch gestures on a bezel sensor to the shelf.
+class ShelfBezelEventHandler : public ui::EventHandler {
public:
- explicit ShelfBezelEventFilter(ShelfLayoutManager* shelf_layout_manager);
- ~ShelfBezelEventFilter() override;
+ explicit ShelfBezelEventHandler(WmShelf* shelf);
+ ~ShelfBezelEventHandler() override;
// Overridden from ui::EventHandler:
void OnGestureEvent(ui::GestureEvent* event) override;
@@ -29,12 +28,12 @@ class ShelfBezelEventFilter : public ui::EventHandler {
private:
bool IsShelfOnBezel(const gfx::Rect& screen, const gfx::Point& point) const;
- ShelfLayoutManager* shelf_layout_manager_;
+ WmShelf* shelf_;
bool in_touch_drag_;
- DISALLOW_COPY_AND_ASSIGN(ShelfBezelEventFilter);
+ DISALLOW_COPY_AND_ASSIGN(ShelfBezelEventHandler);
};
} // namespace ash
-#endif // ASH_SHELF_SHELF_BEZEL_EVENT_FILTER_H_
+#endif // ASH_SHELF_SHELF_BEZEL_EVENT_HANDLER_H_

Powered by Google App Engine
This is Rietveld 408576698