Chromium Code Reviews| Index: chrome/browser/extensions/extension_host.cc |
| diff --git a/chrome/browser/extensions/extension_host.cc b/chrome/browser/extensions/extension_host.cc |
| index 74ca03287af1b8b67085dbe5156025f093dc2bc3..6c72d0ce9db8ac478d6455fb00e6d0193731127b 100644 |
| --- a/chrome/browser/extensions/extension_host.cc |
| +++ b/chrome/browser/extensions/extension_host.cc |
| @@ -515,12 +515,6 @@ WebPreferences ExtensionHost::GetWebkitPrefs() { |
| webkit_prefs.accelerated_2d_canvas_enabled = false; |
| } |
| - // TODO(dcheng): incorporate this setting into kClipboardPermission check. |
| - webkit_prefs.javascript_can_access_clipboard = true; |
| - |
| - // TODO(dcheng): check kClipboardPermission instead once it's implemented. |
| - if (extension_->HasApiPermission(Extension::kExperimentalPermission)) |
| - webkit_prefs.dom_paste_enabled = true; |
| return webkit_prefs; |
| } |
| @@ -670,6 +664,16 @@ void ExtensionHost::ShowPopupMenu(const gfx::Rect& bounds, |
| #endif |
| } |
| +bool ExtensionHost::IsCopyCutEnabled() { |
| + // For backwards compatibility, extensions can always copy/cut items into the |
| + // clipboard. |
| + return true; |
| +} |
| + |
| +bool ExtensionHost::IsPasteEnabled() { |
| + return extension_->HasApiPermission(Extension::kClipboardPermission); |
|
rniwa-cr
2011/02/16 03:41:50
Is extension_ origin controlled? i.e. only script
|
| +} |
| + |
| void ExtensionHost::StartDragging(const WebDropData& drop_data, |
| WebDragOperationsMask operation_mask, |
| const SkBitmap& image, |