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_WM_PARTIAL_SCREENSHOT_VIEW_H_ | 5 #ifndef ASH_WM_PARTIAL_SCREENSHOT_VIEW_H_ |
6 #define ASH_WM_PARTIAL_SCREENSHOT_VIEW_H_ | 6 #define ASH_WM_PARTIAL_SCREENSHOT_VIEW_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "ash/ash_export.h" | 10 #include "ash/ash_export.h" |
(...skipping 30 matching lines...) Expand all Loading... |
41 void Init(aura::Window* root_window); | 41 void Init(aura::Window* root_window); |
42 | 42 |
43 // Returns the currently selected region. | 43 // Returns the currently selected region. |
44 gfx::Rect GetScreenshotRect() const; | 44 gfx::Rect GetScreenshotRect() const; |
45 | 45 |
46 void OnSelectionStarted(const gfx::Point& position); | 46 void OnSelectionStarted(const gfx::Point& position); |
47 void OnSelectionChanged(const gfx::Point& position); | 47 void OnSelectionChanged(const gfx::Point& position); |
48 void OnSelectionFinished(); | 48 void OnSelectionFinished(); |
49 | 49 |
50 // Overridden from views::View: | 50 // Overridden from views::View: |
51 virtual gfx::NativeCursor GetCursor(const ui::MouseEvent& event) OVERRIDE; | 51 virtual gfx::NativeCursor GetCursor(const ui::MouseEvent& event) override; |
52 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE; | 52 virtual void OnPaint(gfx::Canvas* canvas) override; |
53 virtual bool OnMousePressed(const ui::MouseEvent& event) OVERRIDE; | 53 virtual bool OnMousePressed(const ui::MouseEvent& event) override; |
54 virtual bool OnMouseDragged(const ui::MouseEvent& event) OVERRIDE; | 54 virtual bool OnMouseDragged(const ui::MouseEvent& event) override; |
55 virtual bool OnMouseWheel(const ui::MouseWheelEvent& event) OVERRIDE; | 55 virtual bool OnMouseWheel(const ui::MouseWheelEvent& event) override; |
56 virtual void OnMouseReleased(const ui::MouseEvent& event) OVERRIDE; | 56 virtual void OnMouseReleased(const ui::MouseEvent& event) override; |
57 virtual void OnMouseCaptureLost() OVERRIDE; | 57 virtual void OnMouseCaptureLost() override; |
58 virtual void OnGestureEvent(ui::GestureEvent* event) OVERRIDE; | 58 virtual void OnGestureEvent(ui::GestureEvent* event) override; |
59 | 59 |
60 bool is_dragging_; | 60 bool is_dragging_; |
61 gfx::Point start_position_; | 61 gfx::Point start_position_; |
62 gfx::Point current_position_; | 62 gfx::Point current_position_; |
63 | 63 |
64 // The delegate to receive Cancel. No ownership. | 64 // The delegate to receive Cancel. No ownership. |
65 OverlayDelegate* overlay_delegate_; | 65 OverlayDelegate* overlay_delegate_; |
66 | 66 |
67 // ScreenshotDelegate to take the actual screenshot. No ownership. | 67 // ScreenshotDelegate to take the actual screenshot. No ownership. |
68 ScreenshotDelegate* screenshot_delegate_; | 68 ScreenshotDelegate* screenshot_delegate_; |
69 | 69 |
70 DISALLOW_COPY_AND_ASSIGN(PartialScreenshotView); | 70 DISALLOW_COPY_AND_ASSIGN(PartialScreenshotView); |
71 }; | 71 }; |
72 | 72 |
73 } // namespace ash | 73 } // namespace ash |
74 | 74 |
75 #endif // #ifndef ASH_WM_PARTIAL_SCREENSHOT_VIEW_H_ | 75 #endif // #ifndef ASH_WM_PARTIAL_SCREENSHOT_VIEW_H_ |
OLD | NEW |