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

Unified Diff: content/renderer/gpu_benchmarking_extension.cc

Issue 10532058: added gpu_benchmarking_extension boilerplate and hooked it up to a new switch. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: content/renderer/gpu_benchmarking_extension.cc
diff --git a/content/renderer/gpu_benchmarking_extension.cc b/content/renderer/gpu_benchmarking_extension.cc
new file mode 100644
index 0000000000000000000000000000000000000000..1f11e2867a0f72566385f3f3ea0c1815a4c57c15
--- /dev/null
+++ b/content/renderer/gpu_benchmarking_extension.cc
@@ -0,0 +1,28 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "content/renderer/gpu_benchmarking_extension.h"
+
+#include "v8/include/v8.h"
+
+const char kGpuBenchmarkingExtensionName[] = "v8/GpuBenchmarking";
+
+namespace content {
+
+class GpuBenchmarkingWrapper : public v8::Extension {
+ public:
+ GpuBenchmarkingWrapper() :
+ v8::Extension(kGpuBenchmarkingExtensionName, "") {}
nduca 2012/06/08 00:36:03 lets put an empty object in here to establish the
dmurph 2012/06/08 18:36:22 Done.
+
+ virtual v8::Handle<v8::FunctionTemplate> GetNativeFunction(
+ v8::Handle<v8::String> name) {
+ return v8::Handle<v8::FunctionTemplate>();
+ }
+};
+
+v8::Extension* GpuBenchmarkingExtension::Get() {
+ return new GpuBenchmarkingWrapper();
+}
+
+} // namespace content

Powered by Google App Engine
This is Rietveld 408576698