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

Unified Diff: ui/base/clipboard/clipboard_mac.mm

Issue 8805030: Revert 113040 - Enable custom MIME types in web copy/paste. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years 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
« no previous file with comments | « ui/base/clipboard/clipboard_gtk.cc ('k') | ui/base/clipboard/clipboard_util_win.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/base/clipboard/clipboard_mac.mm
===================================================================
--- ui/base/clipboard/clipboard_mac.mm (revision 113044)
+++ ui/base/clipboard/clipboard_mac.mm (working copy)
@@ -15,7 +15,6 @@
#include "base/utf_string_conversions.h"
#import "third_party/mozilla/NSPasteboard+Utils.h"
#include "third_party/skia/include/core/SkBitmap.h"
-#include "ui/base/clipboard/custom_data_helper.h"
#include "ui/gfx/canvas_skia.h"
#include "ui/gfx/scoped_ns_graphics_context_save_gstate_mac.h"
#include "ui/gfx/size.h"
@@ -31,9 +30,6 @@
// actual data associated with this type.
NSString* const kWebSmartPastePboardType = @"NeXT smart paste pasteboard type";
-// TODO(dcheng): This name is temporary. See crbug.com/106449.
-NSString* const kWebCustomDataType = @"org.chromium.web-custom-data";
-
NSPasteboard* GetPasteboard() {
// The pasteboard should not be nil in a UI session, but this handy DCHECK
// can help track down problems if someone tries using clipboard code outside
@@ -228,13 +224,6 @@
if ([NSImage canInitWithPasteboard:GetPasteboard()])
types->push_back(UTF8ToUTF16(kMimeTypePNG));
*contains_filenames = false;
-
- NSPasteboard* pb = GetPasteboard();
- if ([[pb types] containsObject:kWebCustomDataType]) {
- NSData* data = [pb dataForType:kWebCustomDataType];
- if ([data length])
- ReadCustomDataTypes([data bytes], [data length], types);
- }
}
void Clipboard::ReadText(Clipboard::Buffer buffer, string16* result) const {
@@ -320,14 +309,8 @@
void Clipboard::ReadCustomData(Buffer buffer,
const string16& type,
string16* result) const {
- DCHECK_EQ(buffer, BUFFER_STANDARD);
-
- NSPasteboard* pb = GetPasteboard();
- if ([[pb types] containsObject:kWebCustomDataType]) {
- NSData* data = [pb dataForType:kWebCustomDataType];
- if ([data length])
- ReadCustomDataForType([data bytes], [data length], type, result);
- }
+ // TODO(dcheng): Implement this.
+ NOTIMPLEMENTED();
}
void Clipboard::ReadBookmark(string16* title, std::string* url) const {
@@ -433,9 +416,4 @@
return base::SysNSStringToUTF8(kWebSmartPastePboardType);
}
-// static
-Clipboard::FormatType Clipboard::GetWebCustomDataFormatType() {
- return base::SysNSStringToUTF8(kWebCustomDataType);
-}
-
} // namespace ui
« no previous file with comments | « ui/base/clipboard/clipboard_gtk.cc ('k') | ui/base/clipboard/clipboard_util_win.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698