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_SYSTEM_CHROMEOS_PALETTE_CAPTURE_REGION_ACTION_H_ | 5 #ifndef ASH_COMMON_SYSTEM_CHROMEOS_PALETTE_CAPTURE_REGION_ACTION_H_ |
6 #define ASH_COMMON_SYSTEM_CHROMEOS_PALETTE_CAPTURE_REGION_ACTION_H_ | 6 #define ASH_COMMON_SYSTEM_CHROMEOS_PALETTE_CAPTURE_REGION_ACTION_H_ |
7 | 7 |
8 #include "ash/ash_export.h" | 8 #include "ash/ash_export.h" |
9 #include "ash/common/system/chromeos/palette/common_palette_tool.h" | 9 #include "ash/common/system/chromeos/palette/common_palette_tool.h" |
| 10 #include "base/memory/weak_ptr.h" |
10 | 11 |
11 namespace ash { | 12 namespace ash { |
12 | 13 |
13 class ASH_EXPORT CaptureRegionAction : public CommonPaletteTool { | 14 class ASH_EXPORT CaptureRegionMode : public CommonPaletteTool { |
14 public: | 15 public: |
15 explicit CaptureRegionAction(Delegate* delegate); | 16 explicit CaptureRegionMode(Delegate* delegate); |
16 ~CaptureRegionAction() override; | 17 ~CaptureRegionMode() override; |
17 | 18 |
18 private: | 19 private: |
19 // PaletteTool: | 20 // PaletteTool: |
20 PaletteGroup GetGroup() const override; | 21 PaletteGroup GetGroup() const override; |
21 PaletteToolId GetToolId() const override; | 22 PaletteToolId GetToolId() const override; |
| 23 gfx::VectorIconId GetActiveTrayIcon() override; |
22 void OnEnable() override; | 24 void OnEnable() override; |
| 25 void OnDisable() override; |
23 views::View* CreateView() override; | 26 views::View* CreateView() override; |
24 | 27 |
25 // CommonPaletteTool: | 28 // CommonPaletteTool: |
26 gfx::VectorIconId GetPaletteIconId() override; | 29 gfx::VectorIconId GetPaletteIconId() override; |
27 | 30 |
28 DISALLOW_COPY_AND_ASSIGN(CaptureRegionAction); | 31 void OnScreenshotDone(); |
| 32 |
| 33 base::WeakPtrFactory<CaptureRegionMode> weak_factory_; |
| 34 |
| 35 DISALLOW_COPY_AND_ASSIGN(CaptureRegionMode); |
29 }; | 36 }; |
30 | 37 |
31 } // namespace ash | 38 } // namespace ash |
32 | 39 |
33 #endif // ASH_COMMON_SYSTEM_CHROMEOS_PALETTE_CAPTURE_REGION_ACTION_H_ | 40 #endif // ASH_COMMON_SYSTEM_CHROMEOS_PALETTE_CAPTURE_REGION_ACTION_H_ |
OLD | NEW |