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

Side by Side Diff: chrome/renderer/extensions/dispatcher.cc

Issue 11038021: Implement Chrome Extension TabCapture API. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/renderer/extensions/dispatcher.h" 5 #include "chrome/renderer/extensions/dispatcher.h"
6 6
7 #include "base/callback.h" 7 #include "base/callback.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/string_piece.h" 10 #include "base/string_piece.h"
(...skipping 636 matching lines...) Expand 10 before | Expand all | Expand 10 after
647 source_map_.RegisterSource("contextMenus", 647 source_map_.RegisterSource("contextMenus",
648 IDR_CONTEXT_MENUS_CUSTOM_BINDINGS_JS); 648 IDR_CONTEXT_MENUS_CUSTOM_BINDINGS_JS);
649 source_map_.RegisterSource("declarativeWebRequest", 649 source_map_.RegisterSource("declarativeWebRequest",
650 IDR_DECLARATIVE_WEBREQUEST_CUSTOM_BINDINGS_JS); 650 IDR_DECLARATIVE_WEBREQUEST_CUSTOM_BINDINGS_JS);
651 source_map_.RegisterSource("devtools", IDR_DEVTOOLS_CUSTOM_BINDINGS_JS); 651 source_map_.RegisterSource("devtools", IDR_DEVTOOLS_CUSTOM_BINDINGS_JS);
652 source_map_.RegisterSource("experimental.bluetooth", 652 source_map_.RegisterSource("experimental.bluetooth",
653 IDR_EXPERIMENTAL_BLUETOOTH_CUSTOM_BINDINGS_JS); 653 IDR_EXPERIMENTAL_BLUETOOTH_CUSTOM_BINDINGS_JS);
654 source_map_.RegisterSource( 654 source_map_.RegisterSource(
655 "experimental.mediaGalleries", 655 "experimental.mediaGalleries",
656 IDR_EXPERIMENTAL_MEDIA_GALLERIES_CUSTOM_BINDINGS_JS); 656 IDR_EXPERIMENTAL_MEDIA_GALLERIES_CUSTOM_BINDINGS_JS);
657 source_map_.RegisterSource("experimental.tabCapture",
658 IDR_EXPERIMENTAL_TAB_CAPTURE_CUSTOM_BINDINGS_JS);
657 source_map_.RegisterSource("experimental.offscreen", 659 source_map_.RegisterSource("experimental.offscreen",
658 IDR_EXPERIMENTAL_OFFSCREENTABS_CUSTOM_BINDINGS_JS); 660 IDR_EXPERIMENTAL_OFFSCREENTABS_CUSTOM_BINDINGS_JS);
659 source_map_.RegisterSource("experimental.usb", 661 source_map_.RegisterSource("experimental.usb",
660 IDR_EXPERIMENTAL_USB_CUSTOM_BINDINGS_JS); 662 IDR_EXPERIMENTAL_USB_CUSTOM_BINDINGS_JS);
661 source_map_.RegisterSource("extension", IDR_EXTENSION_CUSTOM_BINDINGS_JS); 663 source_map_.RegisterSource("extension", IDR_EXTENSION_CUSTOM_BINDINGS_JS);
662 source_map_.RegisterSource("fileBrowserHandler", 664 source_map_.RegisterSource("fileBrowserHandler",
663 IDR_FILE_BROWSER_HANDLER_CUSTOM_BINDINGS_JS); 665 IDR_FILE_BROWSER_HANDLER_CUSTOM_BINDINGS_JS);
664 source_map_.RegisterSource("fileBrowserPrivate", 666 source_map_.RegisterSource("fileBrowserPrivate",
665 IDR_FILE_BROWSER_PRIVATE_CUSTOM_BINDINGS_JS); 667 IDR_FILE_BROWSER_PRIVATE_CUSTOM_BINDINGS_JS);
666 source_map_.RegisterSource("fileSystem", 668 source_map_.RegisterSource("fileSystem",
(...skipping 444 matching lines...) Expand 10 before | Expand all | Expand 10 after
1111 // we should abort. 1113 // we should abort.
1112 WebKit::WebFrame* frame = context->web_frame(); 1114 WebKit::WebFrame* frame = context->web_frame();
1113 ExtensionURLInfo url_info(frame->document().securityOrigin(), 1115 ExtensionURLInfo url_info(frame->document().securityOrigin(),
1114 UserScriptSlave::GetDataSourceURLForFrame(frame)); 1116 UserScriptSlave::GetDataSourceURLForFrame(frame));
1115 CHECK(!extensions_.IsSandboxedPage(url_info)); 1117 CHECK(!extensions_.IsSandboxedPage(url_info));
1116 1118
1117 return true; 1119 return true;
1118 } 1120 }
1119 1121
1120 } // namespace extensions 1122 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698