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

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

Issue 1097583004: Move the Extension Port implementation out of messaging.js into its own file port.js. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 8 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "extensions/renderer/dispatcher.h" 5 #include "extensions/renderer/dispatcher.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/debug/alias.h" 10 #include "base/debug/alias.h"
(...skipping 492 matching lines...) Expand 10 before | Expand all | Expand 10 after
503 IDR_GUEST_VIEW_CONTAINER_JS)); 503 IDR_GUEST_VIEW_CONTAINER_JS));
504 resources.push_back(std::make_pair("guestViewDeny", IDR_GUEST_VIEW_DENY_JS)); 504 resources.push_back(std::make_pair("guestViewDeny", IDR_GUEST_VIEW_DENY_JS));
505 resources.push_back(std::make_pair("guestViewEvents", 505 resources.push_back(std::make_pair("guestViewEvents",
506 IDR_GUEST_VIEW_EVENTS_JS)); 506 IDR_GUEST_VIEW_EVENTS_JS));
507 resources.push_back(std::make_pair("imageUtil", IDR_IMAGE_UTIL_JS)); 507 resources.push_back(std::make_pair("imageUtil", IDR_IMAGE_UTIL_JS));
508 resources.push_back(std::make_pair("json_schema", IDR_JSON_SCHEMA_JS)); 508 resources.push_back(std::make_pair("json_schema", IDR_JSON_SCHEMA_JS));
509 resources.push_back(std::make_pair("lastError", IDR_LAST_ERROR_JS)); 509 resources.push_back(std::make_pair("lastError", IDR_LAST_ERROR_JS));
510 resources.push_back(std::make_pair("messaging", IDR_MESSAGING_JS)); 510 resources.push_back(std::make_pair("messaging", IDR_MESSAGING_JS));
511 resources.push_back(std::make_pair("messaging_utils", 511 resources.push_back(std::make_pair("messaging_utils",
512 IDR_MESSAGING_UTILS_JS)); 512 IDR_MESSAGING_UTILS_JS));
513 resources.push_back(std::make_pair("port", IDR_PORT_JS));
513 resources.push_back(std::make_pair(kSchemaUtils, IDR_SCHEMA_UTILS_JS)); 514 resources.push_back(std::make_pair(kSchemaUtils, IDR_SCHEMA_UTILS_JS));
514 resources.push_back(std::make_pair("sendRequest", IDR_SEND_REQUEST_JS)); 515 resources.push_back(std::make_pair("sendRequest", IDR_SEND_REQUEST_JS));
515 resources.push_back(std::make_pair("setIcon", IDR_SET_ICON_JS)); 516 resources.push_back(std::make_pair("setIcon", IDR_SET_ICON_JS));
516 resources.push_back(std::make_pair("surfaceWorker", IDR_SURFACE_VIEW_JS)); 517 resources.push_back(std::make_pair("surfaceWorker", IDR_SURFACE_VIEW_JS));
517 resources.push_back(std::make_pair("test", IDR_TEST_CUSTOM_BINDINGS_JS)); 518 resources.push_back(std::make_pair("test", IDR_TEST_CUSTOM_BINDINGS_JS));
518 resources.push_back( 519 resources.push_back(
519 std::make_pair("test_environment_specific_bindings", 520 std::make_pair("test_environment_specific_bindings",
520 IDR_BROWSER_TEST_ENVIRONMENT_SPECIFIC_BINDINGS_JS)); 521 IDR_BROWSER_TEST_ENVIRONMENT_SPECIFIC_BINDINGS_JS));
521 resources.push_back(std::make_pair("uncaught_exception_handler", 522 resources.push_back(std::make_pair("uncaught_exception_handler",
522 IDR_UNCAUGHT_EXCEPTION_HANDLER_JS)); 523 IDR_UNCAUGHT_EXCEPTION_HANDLER_JS));
(...skipping 919 matching lines...) Expand 10 before | Expand all | Expand 10 after
1442 // The "guestViewDeny" module must always be loaded last. It registers 1443 // The "guestViewDeny" module must always be loaded last. It registers
1443 // error-providing custom elements for the GuestView types that are not 1444 // error-providing custom elements for the GuestView types that are not
1444 // available, and thus all of those types must have been checked and loaded 1445 // available, and thus all of those types must have been checked and loaded
1445 // (or not loaded) beforehand. 1446 // (or not loaded) beforehand.
1446 if (context_type == Feature::BLESSED_EXTENSION_CONTEXT) { 1447 if (context_type == Feature::BLESSED_EXTENSION_CONTEXT) {
1447 module_system->Require("guestViewDeny"); 1448 module_system->Require("guestViewDeny");
1448 } 1449 }
1449 } 1450 }
1450 1451
1451 } // namespace extensions 1452 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698