OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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/js_only_v8_extensions.h" | 5 #include "chrome/renderer/extensions/js_only_v8_extensions.h" |
6 | 6 |
7 #include "chrome/renderer/extensions/bindings_utils.h" | 7 #include "chrome/renderer/extensions/bindings_utils.h" |
8 #include "grit/renderer_resources.h" | 8 #include "grit/renderer_resources.h" |
9 #include "grit/webkit_resources.h" | 9 #include "grit/webkit_resources.h" |
10 | 10 |
11 using bindings_utils::GetStringResource; | 11 using bindings_utils::GetStringResource; |
12 | 12 |
13 // BaseJsV8Extension | 13 // BaseJsV8Extension |
14 const char* BaseJsV8Extension::kName = "chrome/base"; | 14 const char* BaseJsV8Extension::kName = "chrome/base"; |
15 v8::Extension* BaseJsV8Extension::Get() { | 15 v8::Extension* BaseJsV8Extension::Get() { |
16 static v8::Extension* extension = | 16 static v8::Extension* extension = |
17 new v8::Extension(kName, GetStringResource<IDR_DEVTOOLS_BASE_JS>(), | 17 new bindings_utils::ExtensionBase( |
18 0, NULL); | 18 kName, GetStringResource<IDR_DEVTOOLS_BASE_JS>(), 0, NULL); |
19 return extension; | 19 return extension; |
20 } | 20 } |
21 | 21 |
22 // JsonSchemaJsV8Extension | 22 // JsonSchemaJsV8Extension |
23 const char* JsonSchemaJsV8Extension::kName = "chrome/jsonschema"; | 23 const char* JsonSchemaJsV8Extension::kName = "chrome/jsonschema"; |
24 v8::Extension* JsonSchemaJsV8Extension::Get() { | 24 v8::Extension* JsonSchemaJsV8Extension::Get() { |
25 static v8::Extension* extension = | 25 static v8::Extension* extension = |
26 new v8::Extension(kName, GetStringResource<IDR_JSON_SCHEMA_JS>(), | 26 new bindings_utils::ExtensionBase( |
27 0, NULL); | 27 kName, GetStringResource<IDR_JSON_SCHEMA_JS>(), 0, NULL); |
28 return extension; | 28 return extension; |
29 } | 29 } |
OLD | NEW |