OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CHROME_BROWSER_UI_BOOKMARKS_BOOKMARK_DRAG_DROP_H_ | 5 #ifndef CHROME_BROWSER_UI_BOOKMARKS_BOOKMARK_DRAG_DROP_H_ |
6 #define CHROME_BROWSER_UI_BOOKMARKS_BOOKMARK_DRAG_DROP_H_ | 6 #define CHROME_BROWSER_UI_BOOKMARKS_BOOKMARK_DRAG_DROP_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "ui/base/dragdrop/drag_drop_types.h" | 10 #include "ui/base/dragdrop/drag_drop_types.h" |
11 #include "ui/gfx/native_widget_types.h" | 11 #include "ui/gfx/native_widget_types.h" |
12 | 12 |
13 class BookmarkNode; | 13 class BookmarkNode; |
| 14 class Profile; |
| 15 |
| 16 namespace bookmarks { |
14 struct BookmarkNodeData; | 17 struct BookmarkNodeData; |
15 class Profile; | 18 } |
16 | 19 |
17 namespace chrome { | 20 namespace chrome { |
18 | 21 |
19 // Starts the process of dragging a folder of bookmarks. | 22 // Starts the process of dragging a folder of bookmarks. |
20 void DragBookmarks(Profile* profile, | 23 void DragBookmarks(Profile* profile, |
21 const std::vector<const BookmarkNode*>& nodes, | 24 const std::vector<const BookmarkNode*>& nodes, |
22 gfx::NativeView view, | 25 gfx::NativeView view, |
23 ui::DragDropTypes::DragEventSource source); | 26 ui::DragDropTypes::DragEventSource source); |
24 | 27 |
25 // Drops the bookmark nodes that are in |data| onto |parent_node| at |index|. | 28 // Drops the bookmark nodes that are in |data| onto |parent_node| at |index|. |
26 // |copy| indicates the source operation: if true then the bookmarks in |data| | 29 // |copy| indicates the source operation: if true then the bookmarks in |data| |
27 // are copied, otherwise they are moved if they belong to the same |profile|. | 30 // are copied, otherwise they are moved if they belong to the same |profile|. |
28 // Returns the drop type used. | 31 // Returns the drop type used. |
29 int DropBookmarks(Profile* profile, | 32 int DropBookmarks(Profile* profile, |
30 const BookmarkNodeData& data, | 33 const bookmarks::BookmarkNodeData& data, |
31 const BookmarkNode* parent_node, | 34 const BookmarkNode* parent_node, |
32 int index, | 35 int index, |
33 bool copy); | 36 bool copy); |
34 | 37 |
35 } // namespace chrome | 38 } // namespace chrome |
36 | 39 |
37 #endif // CHROME_BROWSER_UI_BOOKMARKS_BOOKMARK_DRAG_DROP_H_ | 40 #endif // CHROME_BROWSER_UI_BOOKMARKS_BOOKMARK_DRAG_DROP_H_ |
OLD | NEW |