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

Unified Diff: chrome/browser/ui/ash/palette_delegate_chromeos.h

Issue 2234203002: Auto open and close the palette on an eject event. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@tool-note
Patch Set: Use weak ptr 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: chrome/browser/ui/ash/palette_delegate_chromeos.h
diff --git a/chrome/browser/ui/ash/palette_delegate_chromeos.h b/chrome/browser/ui/ash/palette_delegate_chromeos.h
index 51e638e6a91ed43ce9b48fba1c19ad0d9552cb1e..78cc1b718a5c071802e5eb1dd961f3f801c66205 100644
--- a/chrome/browser/ui/ash/palette_delegate_chromeos.h
+++ b/chrome/browser/ui/ash/palette_delegate_chromeos.h
@@ -11,11 +11,13 @@
#include "base/compiler_specific.h"
#include "base/macros.h"
#include "base/values.h"
+#include "ui/events/devices/input_device_event_observer.h"
namespace chromeos {
// A class which allows the Ash palette to perform chrome actions.
-class PaletteDelegateChromeOS : public ash::PaletteDelegate {
+class PaletteDelegateChromeOS : public ash::PaletteDelegate,
+ public ui::InputDeviceEventObserver {
public:
PaletteDelegateChromeOS();
~PaletteDelegateChromeOS() override;
@@ -25,9 +27,17 @@ class PaletteDelegateChromeOS : public ash::PaletteDelegate {
void CreateNote() override;
bool HasNoteApp() override;
void SetPartialMagnifierState(bool enabled) override;
+ void SetStylusStateChangedCallback(
+ const OnStylusStateChangedCallback& on_stylus_state_changed) override;
+ bool ShouldAutoOpenPalette() override;
void TakeScreenshot() override;
void TakePartialScreenshot() override;
+ // ui::InputDeviceObserver:
+ void OnStylusStateChanged(ui::StylusState state) override;
+
+ OnStylusStateChangedCallback on_stylus_state_changed_;
+
DISALLOW_COPY_AND_ASSIGN(PaletteDelegateChromeOS);
};
« no previous file with comments | « chrome/browser/resources/settings/device_page/note.html ('k') | chrome/browser/ui/ash/palette_delegate_chromeos.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698