OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_UTILITY_PARTIAL_SCREENSHOT_CONTROLLER_H_ | 5 #ifndef ASH_UTILITY_PARTIAL_SCREENSHOT_CONTROLLER_H_ |
6 #define ASH_UTILITY_PARTIAL_SCREENSHOT_CONTROLLER_H_ | 6 #define ASH_UTILITY_PARTIAL_SCREENSHOT_CONTROLLER_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <map> | 10 #include <map> |
| 11 #include <memory> |
11 | 12 |
12 #include "ash/ash_export.h" | 13 #include "ash/ash_export.h" |
13 #include "ash/shell_observer.h" | 14 #include "ash/shell_observer.h" |
14 #include "base/macros.h" | 15 #include "base/macros.h" |
15 #include "base/memory/scoped_ptr.h" | |
16 #include "ui/events/event_handler.h" | 16 #include "ui/events/event_handler.h" |
17 #include "ui/gfx/display_observer.h" | 17 #include "ui/gfx/display_observer.h" |
18 #include "ui/gfx/geometry/point.h" | 18 #include "ui/gfx/geometry/point.h" |
19 | 19 |
20 namespace aura { | 20 namespace aura { |
21 class Window; | 21 class Window; |
22 } | 22 } |
23 | 23 |
24 namespace ui { | 24 namespace ui { |
25 class LocatedEvent; | 25 class LocatedEvent; |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 uint32_t changed_metrics) override; | 68 uint32_t changed_metrics) override; |
69 | 69 |
70 // The data to build the screenshot region. | 70 // The data to build the screenshot region. |
71 gfx::Point start_position_; | 71 gfx::Point start_position_; |
72 aura::Window* root_window_; | 72 aura::Window* root_window_; |
73 | 73 |
74 // Layers to create the visual effect of region selection. | 74 // Layers to create the visual effect of region selection. |
75 std::map<aura::Window*, PartialScreenshotLayer*> layers_; | 75 std::map<aura::Window*, PartialScreenshotLayer*> layers_; |
76 | 76 |
77 // The object to specify the crosshair cursor. | 77 // The object to specify the crosshair cursor. |
78 scoped_ptr<ScopedCursorSetter> cursor_setter_; | 78 std::unique_ptr<ScopedCursorSetter> cursor_setter_; |
79 | 79 |
80 // ScreenshotDelegate to take the actual screenshot. No ownership. | 80 // ScreenshotDelegate to take the actual screenshot. No ownership. |
81 ScreenshotDelegate* screenshot_delegate_; | 81 ScreenshotDelegate* screenshot_delegate_; |
82 | 82 |
83 DISALLOW_COPY_AND_ASSIGN(PartialScreenshotController); | 83 DISALLOW_COPY_AND_ASSIGN(PartialScreenshotController); |
84 }; | 84 }; |
85 | 85 |
86 } // namespace ash | 86 } // namespace ash |
87 | 87 |
88 #endif // #ifndef ASH_WM_PARTIAL_SCREENSHOT_VIEW_H_ | 88 #endif // #ifndef ASH_WM_PARTIAL_SCREENSHOT_VIEW_H_ |
OLD | NEW |