OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 APP_WIN_DROP_TARGET_H_ | 5 #ifndef UI_BASE_DRAGDROP_DROP_TARGET_H_ |
6 #define APP_WIN_DROP_TARGET_H_ | 6 #define UI_BASE_DRAGDROP_DROP_TARGET_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <objidl.h> | 9 #include <objidl.h> |
10 | 10 |
11 #include "base/ref_counted.h" | 11 #include "base/ref_counted.h" |
12 | 12 |
13 // Windows interface. | 13 // Windows interface. |
14 struct IDropTargetHelper; | 14 struct IDropTargetHelper; |
15 | 15 |
16 namespace app { | 16 namespace ui { |
17 namespace win { | |
18 | 17 |
19 // A DropTarget implementation that takes care of the nitty gritty | 18 // A DropTarget implementation that takes care of the nitty gritty |
20 // of dnd. While this class is concrete, subclasses will most likely | 19 // of dnd. While this class is concrete, subclasses will most likely |
21 // want to override various OnXXX methods. | 20 // want to override various OnXXX methods. |
22 // | 21 // |
23 // Because DropTarget is ref counted you shouldn't delete it directly, | 22 // Because DropTarget is ref counted you shouldn't delete it directly, |
24 // rather wrap it in a scoped_refptr. Be sure and invoke RevokeDragDrop(m_hWnd) | 23 // rather wrap it in a scoped_refptr. Be sure and invoke RevokeDragDrop(m_hWnd) |
25 // before the HWND is deleted too. | 24 // before the HWND is deleted too. |
26 // | 25 // |
27 // This class is meant to be used in a STA and is not multithread-safe. | 26 // This class is meant to be used in a STA and is not multithread-safe. |
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
123 | 122 |
124 // Whether or not we are currently processing drag notifications for drags | 123 // Whether or not we are currently processing drag notifications for drags |
125 // initiated in this window. | 124 // initiated in this window. |
126 bool suspended_; | 125 bool suspended_; |
127 | 126 |
128 LONG ref_count_; | 127 LONG ref_count_; |
129 | 128 |
130 DISALLOW_COPY_AND_ASSIGN(DropTarget); | 129 DISALLOW_COPY_AND_ASSIGN(DropTarget); |
131 }; | 130 }; |
132 | 131 |
133 } // namespace win | 132 } // namespace ui |
134 } // namespace app | |
135 | 133 |
136 #endif // APP_WIN_DROP_TARGET_H_ | 134 #endif // UI_BASE_DRAGDROP_DROP_TARGET_H_ |
OLD | NEW |