diff options
author | hanxi <hanxi@chromium.org> | 2014-09-24 12:16:55 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-09-24 19:17:53 +0000 |
commit | faa99f8c03c439f26c5ff497d3804b0818f1cf2f (patch) | |
tree | a30aced2325f3bcb448956c104ee351ee656e775 | |
parent | 39b6931a068a09a41865f1cb43589eb84136da78 (diff) | |
download | chromium_src-faa99f8c03c439f26c5ff497d3804b0818f1cf2f.zip chromium_src-faa99f8c03c439f26c5ff497d3804b0818f1cf2f.tar.gz chromium_src-faa99f8c03c439f26c5ff497d3804b0818f1cf2f.tar.bz2 |
Move declarative_webrequest_custom_bindings.js. and declarative_web_request.json to //extensions.
BUG=352293
Review URL: https://codereview.chromium.org/595033002
Cr-Commit-Position: refs/heads/master@{#296484}
-rw-r--r-- | chrome/chrome_renderer.gypi | 1 | ||||
-rwxr-xr-x | chrome/common/extensions/docs/server2/api_models_test.py | 17 | ||||
-rwxr-xr-x | chrome/common/extensions/docs/server2/platform_bundle_test.py | 2 | ||||
-rw-r--r-- | chrome/common/extensions_api_resources.grd | 1 | ||||
-rw-r--r-- | chrome/renderer/extensions/chrome_extensions_dispatcher_delegate.cc | 2 | ||||
-rw-r--r-- | chrome/renderer/resources/renderer_resources.grd | 1 | ||||
-rw-r--r-- | extensions/common/api/declarative_web_request.json (renamed from chrome/common/extensions/api/declarative_web_request.json) | 0 | ||||
-rw-r--r-- | extensions/extensions.gyp | 1 | ||||
-rw-r--r-- | extensions/extensions_resources.grd | 1 | ||||
-rw-r--r-- | extensions/renderer/BUILD.gn | 1 | ||||
-rw-r--r-- | extensions/renderer/dispatcher.cc | 3 | ||||
-rw-r--r-- | extensions/renderer/resources/declarative_webrequest_custom_bindings.js (renamed from chrome/renderer/resources/extensions/declarative_webrequest_custom_bindings.js) | 0 | ||||
-rw-r--r-- | extensions/renderer/resources/extensions_renderer_resources.grd | 1 |
13 files changed, 15 insertions, 16 deletions
diff --git a/chrome/chrome_renderer.gypi b/chrome/chrome_renderer.gypi index 270d68f..fb28f98 100644 --- a/chrome/chrome_renderer.gypi +++ b/chrome/chrome_renderer.gypi @@ -149,7 +149,6 @@ 'renderer/resources/extensions/chrome_setting.js', 'renderer/resources/extensions/content_setting.js', 'renderer/resources/extensions/declarative_content_custom_bindings.js', - 'renderer/resources/extensions/declarative_webrequest_custom_bindings.js', 'renderer/resources/extensions/enterprise_platform_keys_custom_bindings.js', 'renderer/resources/extensions/extension_options.js', 'renderer/resources/extensions/feedback_private_custom_bindings.js', diff --git a/chrome/common/extensions/docs/server2/api_models_test.py b/chrome/common/extensions/docs/server2/api_models_test.py index fe61e50..f9c863e4 100755 --- a/chrome/common/extensions/docs/server2/api_models_test.py +++ b/chrome/common/extensions/docs/server2/api_models_test.py @@ -39,8 +39,6 @@ _TEST_DATA = { '_manifest_features.json': '{}', '_permission_features.json': '{}', 'alarms.idl': ReadFile(CHROME_API, 'alarms.idl'), - 'declarative_web_request.json': ReadFile( - CHROME_API, 'declarative_web_request.json'), 'input_ime.json': ReadFile(CHROME_API, 'input_ime.json'), 'page_action.json': ReadFile(CHROME_API, 'page_action.json'), }, @@ -95,13 +93,6 @@ class APIModelsTest(unittest.TestCase): self.assertEqual('alarms', get_model_name('alarms')) self.assertEqual('alarms', get_model_name('alarms.idl')) self.assertEqual('alarms', get_model_name(CHROME_API + 'alarms.idl')) - self.assertEqual('declarativeWebRequest', - get_model_name('declarativeWebRequest')) - self.assertEqual('declarativeWebRequest', - get_model_name('declarative_web_request.json')) - self.assertEqual('declarativeWebRequest', - get_model_name(CHROME_API + - 'declarative_web_request.json')) self.assertEqual('input.ime', get_model_name('input.ime')) self.assertEqual('input.ime', get_model_name('input_ime.json')) self.assertEqual('input.ime', @@ -113,6 +104,14 @@ class APIModelsTest(unittest.TestCase): def testGetNonexistentModel(self): self.assertRaises(FileNotFoundError, + self._api_models.GetModel('declarativeWebRequest').Get) + self.assertRaises(FileNotFoundError, + self._api_models.GetModel( + 'declarative_web_request.json').Get) + self.assertRaises(FileNotFoundError, + self._api_models.GetModel( + CHROME_API + 'declarative_web_request.json').Get) + self.assertRaises(FileNotFoundError, self._api_models.GetModel('notfound').Get) self.assertRaises(FileNotFoundError, self._api_models.GetModel('notfound.json').Get) diff --git a/chrome/common/extensions/docs/server2/platform_bundle_test.py b/chrome/common/extensions/docs/server2/platform_bundle_test.py index 6e16974..fefecf6 100755 --- a/chrome/common/extensions/docs/server2/platform_bundle_test.py +++ b/chrome/common/extensions/docs/server2/platform_bundle_test.py @@ -33,8 +33,6 @@ _TEST_DATA = { '_manifest_features.json': '{}', '_permission_features.json': '{}', 'alarms.idl': ReadFile(CHROME_API, 'alarms.idl'), - 'declarative_web_request.json': ReadFile( - CHROME_API, 'declarative_web_request.json'), 'input_ime.json': ReadFile(CHROME_API, 'input_ime.json'), 'page_action.json': ReadFile(CHROME_API, 'page_action.json'), }, diff --git a/chrome/common/extensions_api_resources.grd b/chrome/common/extensions_api_resources.grd index 7604414..7bf7de0 100644 --- a/chrome/common/extensions_api_resources.grd +++ b/chrome/common/extensions_api_resources.grd @@ -13,7 +13,6 @@ <include name="IDR_EXTENSION_API_JSON_BROWSERACTION" file="extensions\api\browser_action.json" type="BINDATA" /> <include name="IDR_EXTENSION_API_JSON_COMMANDS" file="extensions\api\commands.json" type="BINDATA" /> <include name="IDR_EXTENSION_API_JSON_DECLARATIVE_CONTENT" file="extensions\api\declarative_content.json" type="BINDATA" /> - <include name="IDR_EXTENSION_API_JSON_DECLARATIVE_WEBREQUEST" file="extensions\api\declarative_web_request.json" type="BINDATA" /> <include name="IDR_EXTENSION_API_JSON_FILEBROWSERHANDLER" file="extensions\api\file_browser_handler.json" type="BINDATA" /> <include name="IDR_EXTENSION_API_JSON_INPUTMETHODPRIVATE" file="extensions\api\input_method_private.json" type="BINDATA" /> <include name="IDR_EXTENSION_API_JSON_PAGEACTION" file="extensions\api\page_action.json" type="BINDATA" /> diff --git a/chrome/renderer/extensions/chrome_extensions_dispatcher_delegate.cc b/chrome/renderer/extensions/chrome_extensions_dispatcher_delegate.cc index b65b153..b408544 100644 --- a/chrome/renderer/extensions/chrome_extensions_dispatcher_delegate.cc +++ b/chrome/renderer/extensions/chrome_extensions_dispatcher_delegate.cc @@ -159,8 +159,6 @@ void ChromeExtensionsDispatcherDelegate::PopulateSourceMap( IDR_BROWSER_ACTION_CUSTOM_BINDINGS_JS); source_map->RegisterSource("declarativeContent", IDR_DECLARATIVE_CONTENT_CUSTOM_BINDINGS_JS); - source_map->RegisterSource("declarativeWebRequest", - IDR_DECLARATIVE_WEBREQUEST_CUSTOM_BINDINGS_JS); source_map->RegisterSource("desktopCapture", IDR_DESKTOP_CAPTURE_CUSTOM_BINDINGS_JS); source_map->RegisterSource("developerPrivate", diff --git a/chrome/renderer/resources/renderer_resources.grd b/chrome/renderer/resources/renderer_resources.grd index ff13977..91dcc38 100644 --- a/chrome/renderer/resources/renderer_resources.grd +++ b/chrome/renderer/resources/renderer_resources.grd @@ -48,7 +48,6 @@ <include name="IDR_CHROME_WEB_VIEW_JS" file="extensions\chrome_web_view.js" type="BINDATA" /> <include name="IDR_CONTENT_SETTING_JS" file="extensions\content_setting.js" type="BINDATA" /> <include name="IDR_DECLARATIVE_CONTENT_CUSTOM_BINDINGS_JS" file="extensions\declarative_content_custom_bindings.js" type="BINDATA" /> - <include name="IDR_DECLARATIVE_WEBREQUEST_CUSTOM_BINDINGS_JS" file="extensions\declarative_webrequest_custom_bindings.js" type="BINDATA" /> <include name="IDR_DESKTOP_CAPTURE_CUSTOM_BINDINGS_JS" file="extensions\desktop_capture_custom_bindings.js" type="BINDATA" /> <include name="IDR_DEVELOPER_PRIVATE_CUSTOM_BINDINGS_JS" file="extensions\developer_private_custom_bindings.js" type="BINDATA" /> <include name="IDR_DOWNLOADS_CUSTOM_BINDINGS_JS" file="extensions\downloads_custom_bindings.js" type="BINDATA" /> diff --git a/chrome/common/extensions/api/declarative_web_request.json b/extensions/common/api/declarative_web_request.json index e9ea8a2..e9ea8a2 100644 --- a/chrome/common/extensions/api/declarative_web_request.json +++ b/extensions/common/api/declarative_web_request.json diff --git a/extensions/extensions.gyp b/extensions/extensions.gyp index 33da867..6178f61 100644 --- a/extensions/extensions.gyp +++ b/extensions/extensions.gyp @@ -848,6 +848,7 @@ 'renderer/resources/app_window_custom_bindings.js', 'renderer/resources/binding.js', 'renderer/resources/context_menus_custom_bindings.js', + 'renderer/resources/declarative_webrequest_custom_bindings.js', 'renderer/resources/entry_id_manager.js', 'renderer/resources/event.js', 'renderer/resources/extension.css', diff --git a/extensions/extensions_resources.grd b/extensions/extensions_resources.grd index de5d4b5..f8b53a9 100644 --- a/extensions/extensions_resources.grd +++ b/extensions/extensions_resources.grd @@ -9,6 +9,7 @@ <release seq="1"> <includes> <include name="IDR_EXTENSION_API_FEATURES" file="common\api\_api_features.json" type="BINDATA" /> + <include name="IDR_EXTENSION_API_JSON_DECLARATIVE_WEBREQUEST" file="common\api\declarative_web_request.json" type="BINDATA" /> <include name="IDR_EXTENSION_MANIFEST_FEATURES" file="common\api\_manifest_features.json" type="BINDATA" /> <include name="IDR_EXTENSION_PERMISSION_FEATURES" file="common\api\_permission_features.json" type="BINDATA" /> </includes> diff --git a/extensions/renderer/BUILD.gn b/extensions/renderer/BUILD.gn index 80ff8d2..a0092c1 100644 --- a/extensions/renderer/BUILD.gn +++ b/extensions/renderer/BUILD.gn @@ -82,6 +82,7 @@ source_set("renderer") { "resources/app_window_custom_bindings.js", "resources/binding.js", "resources/context_menus_custom_bindings.js", + "resources/declarative_webrequest_custom_bindings.js", "resources/entry_id_manager.js", "resources/event.js", "resources/extension.css", diff --git a/extensions/renderer/dispatcher.cc b/extensions/renderer/dispatcher.cc index 913146c..278066c 100644 --- a/extensions/renderer/dispatcher.cc +++ b/extensions/renderer/dispatcher.cc @@ -567,6 +567,9 @@ std::vector<std::pair<std::string, int> > Dispatcher::GetJsResources() { resources.push_back( std::make_pair("app.window", IDR_APP_WINDOW_CUSTOM_BINDINGS_JS)); resources.push_back( + std::make_pair("declarativeWebRequest", + IDR_DECLARATIVE_WEBREQUEST_CUSTOM_BINDINGS_JS)); + resources.push_back( std::make_pair("contextMenus", IDR_CONTEXT_MENUS_CUSTOM_BINDINGS_JS)); resources.push_back( std::make_pair("extension", IDR_EXTENSION_CUSTOM_BINDINGS_JS)); diff --git a/chrome/renderer/resources/extensions/declarative_webrequest_custom_bindings.js b/extensions/renderer/resources/declarative_webrequest_custom_bindings.js index 641b782..641b782 100644 --- a/chrome/renderer/resources/extensions/declarative_webrequest_custom_bindings.js +++ b/extensions/renderer/resources/declarative_webrequest_custom_bindings.js diff --git a/extensions/renderer/resources/extensions_renderer_resources.grd b/extensions/renderer/resources/extensions_renderer_resources.grd index 5f8715d..fccb7af 100644 --- a/extensions/renderer/resources/extensions_renderer_resources.grd +++ b/extensions/renderer/resources/extensions_renderer_resources.grd @@ -42,6 +42,7 @@ <include name="IDR_APP_WINDOW_CUSTOM_BINDINGS_JS" file="app_window_custom_bindings.js" type="BINDATA" /> <include name="IDR_BINDING_JS" file="binding.js" type="BINDATA" /> <include name="IDR_CONTEXT_MENUS_CUSTOM_BINDINGS_JS" file="context_menus_custom_bindings.js" type="BINDATA" /> + <include name="IDR_DECLARATIVE_WEBREQUEST_CUSTOM_BINDINGS_JS" file="declarative_webrequest_custom_bindings.js" type="BINDATA" /> <include name="IDR_EXTENSION_CUSTOM_BINDINGS_JS" file="extension_custom_bindings.js" type="BINDATA" /> <include name="IDR_GREASEMONKEY_API_JS" file="greasemonkey_api.js" type="BINDATA" /> <include name="IDR_I18N_CUSTOM_BINDINGS_JS" file="i18n_custom_bindings.js" type="BINDATA" /> |