summaryrefslogtreecommitdiffstats
path: root/base/scoped_clipboard_writer.h
diff options
context:
space:
mode:
authorestade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-04 21:52:29 +0000
committerestade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-04 21:52:29 +0000
commitb08cadb9ab90b41af81b9fd8da65fb52433c8004 (patch)
tree55738edf0c98b596cd6f9a89533e92f5a82c6fff /base/scoped_clipboard_writer.h
parent021d688a1e02ae7bd88e54162d5d25e1dae52e7c (diff)
downloadchromium_src-b08cadb9ab90b41af81b9fd8da65fb52433c8004.zip
chromium_src-b08cadb9ab90b41af81b9fd8da65fb52433c8004.tar.gz
chromium_src-b08cadb9ab90b41af81b9fd8da65fb52433c8004.tar.bz2
GTK: implement bookmark manager copy/paste.
- Refactor bookmark util clipboard code to be cross platform. - Add a CBF_DATA format for writing arbitrary data to the clipboard. - Change MenuGtk so that showing a menu only makes the menu items update asynchronously. This way we can show the menu immediately and we won't get in trouble if the delegate's IsCommandEnabled() runs a nested message loop. I did not do any mac-side implementation of the new clipboard stuff. The implementation should be easy when they get around to writing the bookmark manager. Review URL: http://codereview.chromium.org/159815 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22419 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/scoped_clipboard_writer.h')
-rw-r--r--base/scoped_clipboard_writer.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/base/scoped_clipboard_writer.h b/base/scoped_clipboard_writer.h
index 03ac892..9d1760a 100644
--- a/base/scoped_clipboard_writer.h
+++ b/base/scoped_clipboard_writer.h
@@ -17,6 +17,8 @@
#include "base/file_path.h"
#include "base/string16.h"
+class Pickle;
+
// This class is a wrapper for |Clipboard| that handles packing data
// into a Clipboard::ObjectMap.
// NB: You should probably NOT be using this class if you include
@@ -55,6 +57,9 @@ class ScopedClipboardWriter {
// Pixel format is assumed to be 32-bit BI_RGB.
void WriteBitmapFromPixels(const void* pixels, const gfx::Size& size);
+ // Adds arbitrary data to clipboard.
+ void WritePickledData(const Pickle& pickle, Clipboard::FormatType format);
+
protected:
// We accumulate the data passed to the various targets in the |objects_|
// vector, and pass it to Clipboard::WriteObjects() during object destruction.