| Index: ash/common/palette_delegate.h
|
| diff --git a/ash/common/palette_delegate.h b/ash/common/palette_delegate.h
|
| index 67fda37febd5e60a1b6c097fdca2d30e627a3a38..6daf59e8e4ea2c16a88a8a8a3774f1647f335098 100644
|
| --- a/ash/common/palette_delegate.h
|
| +++ b/ash/common/palette_delegate.h
|
| @@ -7,6 +7,7 @@
|
|
|
| #include "ash/ash_export.h"
|
| #include "base/callback.h"
|
| +#include "base/callback_list.h"
|
| #include "base/macros.h"
|
| #include "ui/events/devices/stylus_state.h"
|
|
|
| @@ -16,10 +17,19 @@ namespace ash {
|
| // Chrome-specific actions.
|
| class PaletteDelegate {
|
| public:
|
| + using EnableListener = base::Callback<void(bool)>;
|
| + using EnableListenerSubscription =
|
| + base::CallbackList<void(bool)>::Subscription;
|
| using OnStylusStateChangedCallback = base::Callback<void(ui::StylusState)>;
|
|
|
| virtual ~PaletteDelegate() {}
|
|
|
| + // Sets callback function that will receive the current state of the palette
|
| + // enabled pref. The callback will be invoked once the initial pref value is
|
| + // available.
|
| + virtual std::unique_ptr<EnableListenerSubscription> AddPaletteEnableListener(
|
| + const EnableListener& on_state_changed) = 0;
|
| +
|
| // Create a new note.
|
| virtual void CreateNote() = 0;
|
|
|
|
|