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

Unified Diff: ash/common/system/chromeos/palette/palette_tray.h

Issue 2644713002: cros: Use runtime stylus detection for ash palette. (Closed)
Patch Set: Fix test Created 3 years, 10 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/palette_delegate.h ('k') | ash/common/system/chromeos/palette/palette_tray.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/common/system/chromeos/palette/palette_tray.h
diff --git a/ash/common/system/chromeos/palette/palette_tray.h b/ash/common/system/chromeos/palette/palette_tray.h
index 7dbc3c0baaf2f78480fba348673f456d0eae52c8..9633c35b729c6ad05b178ce0b9ad0437e777e633 100644
--- a/ash/common/system/chromeos/palette/palette_tray.h
+++ b/ash/common/system/chromeos/palette/palette_tray.h
@@ -16,6 +16,7 @@
#include "ash/common/system/tray/tray_background_view.h"
#include "base/macros.h"
#include "base/memory/weak_ptr.h"
+#include "ui/events/devices/input_device_event_observer.h"
namespace gfx {
class Point;
@@ -38,6 +39,7 @@ class ASH_EXPORT PaletteTray : public TrayBackgroundView,
public SessionStateObserver,
public ShellObserver,
public PaletteToolManager::Delegate,
+ public ui::InputDeviceEventObserver,
public views::TrayBubbleView::Delegate {
public:
explicit PaletteTray(WmShelf* wm_shelf);
@@ -78,6 +80,10 @@ class ASH_EXPORT PaletteTray : public TrayBackgroundView,
bool ContainsPointInScreen(const gfx::Point& point);
private:
+ // ui::InputDeviceObserver:
+ void OnTouchscreenDeviceConfigurationChanged() override;
+ void OnStylusStateChanged(ui::StylusState stylus_state) override;
+
// views::TrayBubbleView::Delegate:
void BubbleViewDestroyed() override;
void OnMouseEnteredView() override;
@@ -103,9 +109,6 @@ class ASH_EXPORT PaletteTray : public TrayBackgroundView,
// Sets the icon to visible if the palette can be used.
void UpdateIconVisibility();
- // Called when a stylus inserted or removed event is received.
- void OnStylusStateChanged(ui::StylusState stylus_state);
-
// Called when the palette enabled pref has changed.
void OnPaletteEnabledPrefChanged(bool enabled);
« no previous file with comments | « ash/common/palette_delegate.h ('k') | ash/common/system/chromeos/palette/palette_tray.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698