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

Unified Diff: chrome/browser/extensions/api/webview/execute_script_function.h

Issue 11968054: <webview>: Implement ExecuteScript (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Renamed misnamed variable Created 7 years, 11 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: chrome/browser/extensions/api/webview/execute_script_function.h
diff --git a/chrome/browser/extensions/api/webview/execute_script_function.h b/chrome/browser/extensions/api/webview/execute_script_function.h
new file mode 100644
index 0000000000000000000000000000000000000000..9ecd9e5850211d08253381583878a514d6105542
--- /dev/null
+++ b/chrome/browser/extensions/api/webview/execute_script_function.h
@@ -0,0 +1,37 @@
+// Copyright (c) 2013 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.
+
+#ifndef CHROME_BROWSER_EXTENSIONS_API_WEBVIEW_EXECUTE_SCRIPT_FUNCTION_H_
+#define CHROME_BROWSER_EXTENSIONS_API_WEBVIEW_EXECUTE_SCRIPT_FUNCTION_H_
+
+#include "base/memory/scoped_ptr.h"
+#include "chrome/browser/extensions/extension_function.h"
+#include "chrome/browser/extensions/script_executor.h"
+
+namespace extensions {
+
+class ExecuteScriptFunction : public AsyncExtensionFunction {
+ public:
+ DECLARE_EXTENSION_FUNCTION("webview.executeScript", WEBVIEW_EXECUTESCRIPT)
+
+ ExecuteScriptFunction();
+
+ protected:
+ virtual ~ExecuteScriptFunction();
+
+ // ExtensionFunction implementation.
+ virtual bool RunImpl() OVERRIDE;
+
+ private:
+
+ void OnExecuteCodeFinished(const std::string& error,
+ int32 on_page_id,
+ const GURL& on_url,
+ const ListValue& result);
+
+};
+
+} // namespace extensions
+
+#endif // CHROME_BROWSER_EXTENSIONS_API_WEBVIEW_EXECUTE_SCRIPT_FUNCTION_H_

Powered by Google App Engine
This is Rietveld 408576698