OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef ASH_COMMON_TEST_TEST_PALETTE_DELEGATE_H_ | 5 #ifndef ASH_COMMON_TEST_TEST_PALETTE_DELEGATE_H_ |
6 #define ASH_COMMON_TEST_TEST_PALETTE_DELEGATE_H_ | 6 #define ASH_COMMON_TEST_TEST_PALETTE_DELEGATE_H_ |
7 | 7 |
8 #include "ash/common/palette_delegate.h" | 8 #include "ash/common/palette_delegate.h" |
9 #include "base/macros.h" | 9 #include "base/macros.h" |
10 | 10 |
(...skipping 18 matching lines...) Expand all Loading... |
29 } | 29 } |
30 | 30 |
31 void set_has_note_app(bool has_note_app) { has_note_app_ = has_note_app; } | 31 void set_has_note_app(bool has_note_app) { has_note_app_ = has_note_app; } |
32 | 32 |
33 void set_should_auto_open_palette(bool should_auto_open_palette) { | 33 void set_should_auto_open_palette(bool should_auto_open_palette) { |
34 should_auto_open_palette_ = should_auto_open_palette; | 34 should_auto_open_palette_ = should_auto_open_palette; |
35 } | 35 } |
36 | 36 |
37 private: | 37 private: |
38 // PaletteDelegate: | 38 // PaletteDelegate: |
| 39 std::unique_ptr<EnableListenerSubscription> AddPaletteEnableListener( |
| 40 const EnableListener& on_state_changed) override; |
39 void CreateNote() override; | 41 void CreateNote() override; |
40 bool HasNoteApp() override; | 42 bool HasNoteApp() override; |
41 void SetPartialMagnifierState(bool enabled) override; | 43 void SetPartialMagnifierState(bool enabled) override; |
42 void SetStylusStateChangedCallback( | 44 void SetStylusStateChangedCallback( |
43 const OnStylusStateChangedCallback& on_stylus_state_changed) override; | 45 const OnStylusStateChangedCallback& on_stylus_state_changed) override; |
44 bool ShouldAutoOpenPalette() override; | 46 bool ShouldAutoOpenPalette() override; |
45 void TakeScreenshot() override; | 47 void TakeScreenshot() override; |
46 void TakePartialScreenshot() override; | 48 void TakePartialScreenshot() override; |
47 | 49 |
48 int create_note_count_ = 0; | 50 int create_note_count_ = 0; |
49 int has_note_app_count_ = 0; | 51 int has_note_app_count_ = 0; |
50 bool partial_magnifier_state_ = false; | 52 bool partial_magnifier_state_ = false; |
51 int take_screenshot_count_ = 0; | 53 int take_screenshot_count_ = 0; |
52 int take_partial_screenshot_count_ = 0; | 54 int take_partial_screenshot_count_ = 0; |
53 bool has_note_app_ = false; | 55 bool has_note_app_ = false; |
54 bool should_auto_open_palette_ = false; | 56 bool should_auto_open_palette_ = false; |
55 | 57 |
56 DISALLOW_COPY_AND_ASSIGN(TestPaletteDelegate); | 58 DISALLOW_COPY_AND_ASSIGN(TestPaletteDelegate); |
57 }; | 59 }; |
58 | 60 |
59 } // namespace ash | 61 } // namespace ash |
60 | 62 |
61 #endif // ASH_COMMON_TEST_TEST_PALETTE_DELEGATE_H_ | 63 #endif // ASH_COMMON_TEST_TEST_PALETTE_DELEGATE_H_ |
OLD | NEW |