Roll ANGLE.
[chromium-blink-merge.git] / components / bookmarks / browser / bookmark_pasteboard_helper_mac.h
blobaecb727b11179b3838c15d0225f5883240bd372e
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
3 // found in the LICENSE file.
5 #ifndef COMPONENTS_BOOKMARKS_BROWSER_BOOKMARK_PASTEBOARD_HELPER_MAC_H_
6 #define COMPONENTS_BOOKMARKS_BROWSER_BOOKMARK_PASTEBOARD_HELPER_MAC_H_
8 #include "components/bookmarks/browser/bookmark_node_data.h"
10 #if defined(__OBJC__)
11 @class NSString;
12 #endif // __OBJC__
14 namespace base {
15 class FilePath;
18 // This set of functions lets C++ code interact with the cocoa pasteboard and
19 // dragging methods.
21 // Writes a set of bookmark elements from a profile to the specified pasteboard.
22 void WriteBookmarksToPasteboard(
23 ui::ClipboardType type,
24 const std::vector<BookmarkNodeData::Element>& elements,
25 const base::FilePath& profile_path);
27 // Reads a set of bookmark elements from the specified pasteboard.
28 bool ReadBookmarksFromPasteboard(
29 ui::ClipboardType type,
30 std::vector<BookmarkNodeData::Element>& elements,
31 base::FilePath* profile_path);
33 // Returns true if the specified pasteboard contains any sort of bookmark
34 // elements. It currently does not consider a plaintext url a valid bookmark.
35 bool PasteboardContainsBookmarks(ui::ClipboardType type);
37 #if defined(__OBJC__)
38 // Pasteboard type for dictionary containing bookmark structure consisting
39 // of individual bookmark nodes and/or bookmark folders.
40 extern "C" NSString* const kBookmarkDictionaryListPboardType;
41 #endif // __OBJC__
43 #endif // COMPONENTS_BOOKMARKS_BROWSER_BOOKMARK_PASTEBOARD_HELPER_MAC_H_