Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1616)

Unified Diff: chrome/browser/bookmarks/bookmark_drag_data.h

Issue 159815: Refactor bookmark clipboard code to be cross platform. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: fix UMR Created 11 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/bookmarks/bookmark_drag_data.h
===================================================================
--- chrome/browser/bookmarks/bookmark_drag_data.h (revision 22359)
+++ chrome/browser/bookmarks/bookmark_drag_data.h (working copy)
@@ -71,6 +71,17 @@
explicit BookmarkDragData(const BookmarkNode* node);
explicit BookmarkDragData(const std::vector<const BookmarkNode*>& nodes);
+ // TODO(estade): Port to mac. It should be as simple as removing this ifdef
+ // after the relevant Clipboard functions are implemetned.
+#if !defined(OS_MACOSX)
+ // Writes elements to the clipboard.
+ void WriteToClipboard(Profile* profile) const;
+
+ // Reads bookmarks from the clipboard. Prefers data written via
+ // WriteToClipboard but will also attempt to read a plain bookmark.
+ bool ReadFromClipboard();
+#endif
+
#if defined(TOOLKIT_VIEWS)
// Writes elements to data. If there is only one element and it is a URL
// the URL and title are written to the clipboard in a format other apps can
@@ -114,6 +125,9 @@
// The actual elements written to the clipboard.
std::vector<Element> elements;
+ // The MIME type for the clipboard format for BookmarkDragData.
+ static const char* kClipboardFormatString;
+
private:
// Path of the profile we originated from.
#if defined(WCHAR_T_IS_UTF16)

Powered by Google App Engine
This is Rietveld 408576698