OLD | NEW |
| (Empty) |
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 | |
3 // found in the LICENSE file. | |
4 | |
5 #include "ash/common/system/chromeos/palette/palette_tool.h" | |
6 | |
7 #include "ash/common/system/chromeos/palette/palette_tool_manager.h" | |
8 #include "ash/common/system/chromeos/palette/palette_utils.h" | |
9 #include "ash/common/system/chromeos/palette/tools/capture_region_mode.h" | |
10 #include "ash/common/system/chromeos/palette/tools/capture_screen_action.h" | |
11 #include "ash/common/system/chromeos/palette/tools/create_note_action.h" | |
12 #include "ash/common/system/chromeos/palette/tools/laser_pointer_mode.h" | |
13 #include "ash/common/system/chromeos/palette/tools/magnifier_mode.h" | |
14 #include "base/memory/ptr_util.h" | |
15 #include "ui/gfx/paint_vector_icon.h" | |
16 | |
17 namespace ash { | |
18 | |
19 // static | |
20 void PaletteTool::RegisterToolInstances(PaletteToolManager* tool_manager) { | |
21 tool_manager->AddTool(base::MakeUnique<CaptureRegionMode>(tool_manager)); | |
22 tool_manager->AddTool(base::MakeUnique<CaptureScreenAction>(tool_manager)); | |
23 tool_manager->AddTool(base::MakeUnique<CreateNoteAction>(tool_manager)); | |
24 tool_manager->AddTool(base::MakeUnique<LaserPointerMode>(tool_manager)); | |
25 tool_manager->AddTool(base::MakeUnique<MagnifierMode>(tool_manager)); | |
26 } | |
27 | |
28 PaletteTool::PaletteTool(Delegate* delegate) : delegate_(delegate) {} | |
29 | |
30 PaletteTool::~PaletteTool() {} | |
31 | |
32 void PaletteTool::OnEnable() { | |
33 enabled_ = true; | |
34 } | |
35 | |
36 void PaletteTool::OnDisable() { | |
37 enabled_ = false; | |
38 } | |
39 | |
40 const gfx::VectorIcon& PaletteTool::GetActiveTrayIcon() const { | |
41 return gfx::kNoneIcon; | |
42 } | |
43 | |
44 } // namespace ash | |
OLD | NEW |