OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_SCREENSHOT_DELEGATE_H_ | 5 #ifndef ASH_SCREENSHOT_DELEGATE_H_ |
6 #define ASH_SCREENSHOT_DELEGATE_H_ | 6 #define ASH_SCREENSHOT_DELEGATE_H_ |
7 | 7 |
8 namespace aura { | 8 namespace aura { |
9 class Window; | 9 class Window; |
10 } // namespace aura | 10 } // namespace aura |
11 | 11 |
12 namespace gfx { | 12 namespace gfx { |
13 class Rect; | 13 class Rect; |
14 } // namespace gfx | 14 } // namespace gfx |
15 | 15 |
16 namespace ash { | 16 namespace ash { |
17 | 17 |
18 // Delegate for taking screenshots. | 18 // Delegate for taking screenshots. |
19 class ScreenshotDelegate { | 19 class ScreenshotDelegate { |
20 public: | 20 public: |
21 virtual ~ScreenshotDelegate() {} | 21 virtual ~ScreenshotDelegate() {} |
22 | 22 |
23 // The actual task of taking a screenshot for each root window. | 23 // The actual task of taking a screenshot for each root window. |
24 // This method is called when the user wants to take a screenshot manually. | 24 // This method is called when the user wants to take a screenshot manually. |
25 virtual void HandleTakeScreenshotForAllRootWindows() = 0; | 25 virtual void HandleTakeScreenshotForAllRootWindows() = 0; |
26 | 26 |
27 // The actual task of taking a partial screenshot for the given | 27 // The actual task of taking a partial screenshot for the given |
28 // window. | 28 // window. |
29 virtual void HandleTakePartialScreenshot( | 29 virtual void HandleTakePartialScreenshot(aura::Window* window, |
30 aura::Window* window, const gfx::Rect& rect) = 0; | 30 const gfx::Rect& rect) = 0; |
31 | 31 |
32 // The actual task of taking screenshot for the given window. | 32 // The actual task of taking screenshot for the given window. |
33 virtual void HandleTakeWindowScreenshot(aura::Window* window) = 0; | 33 virtual void HandleTakeWindowScreenshot(aura::Window* window) = 0; |
34 | 34 |
35 // Returns true if the system is ready to take screenshot. | 35 // Returns true if the system is ready to take screenshot. |
36 virtual bool CanTakeScreenshot() = 0; | 36 virtual bool CanTakeScreenshot() = 0; |
37 }; | 37 }; |
38 } // namespace ash | 38 } // namespace ash |
39 | 39 |
40 #endif // ASH_SCREENSHOT_DELEGATE_H_ | 40 #endif // ASH_SCREENSHOT_DELEGATE_H_ |
OLD | NEW |