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

Unified Diff: chrome/common/render_messages_params.h

Issue 6735004: Move extension messages to their own file and add a RenderViewObserver to start moving the extens... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 9 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
« no previous file with comments | « chrome/common/render_messages.cc ('k') | chrome/common/render_messages_params.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/render_messages_params.h
===================================================================
--- chrome/common/render_messages_params.h (revision 79468)
+++ chrome/common/render_messages_params.h (working copy)
@@ -8,17 +8,8 @@
#include <string>
-#include "base/values.h"
-#include "chrome/common/extensions/extension.h"
-#include "chrome/common/extensions/extension_extent.h"
-#include "chrome/common/extensions/url_pattern.h"
-#include "googleurl/src/gurl.h"
#include "ipc/ipc_param_traits.h"
-namespace net {
-class UploadData;
-}
-
// The type of OSDD that the renderer is giving to the browser.
struct ViewHostMsg_PageHasOSDD_Type {
enum Type {
@@ -104,82 +95,6 @@
}
};
-// Allows an extension to execute code in a tab.
-struct ViewMsg_ExecuteCode_Params {
- ViewMsg_ExecuteCode_Params();
- ViewMsg_ExecuteCode_Params(int request_id, const std::string& extension_id,
- bool is_javascript, const std::string& code,
- bool all_frames);
- ~ViewMsg_ExecuteCode_Params();
-
- // The extension API request id, for responding.
- int request_id;
-
- // The ID of the requesting extension. To know which isolated world to
- // execute the code inside of.
- std::string extension_id;
-
- // Whether the code is JavaScript or CSS.
- bool is_javascript;
-
- // String of code to execute.
- std::string code;
-
- // Whether to inject into all frames, or only the root frame.
- bool all_frames;
-};
-
-struct ViewMsg_ExtensionLoaded_Params {
- ViewMsg_ExtensionLoaded_Params();
- ~ViewMsg_ExtensionLoaded_Params();
- explicit ViewMsg_ExtensionLoaded_Params(const Extension* extension);
-
- // A copy constructor is needed because this structure can end up getting
- // copied inside the IPC machinery on gcc <= 4.2.
- ViewMsg_ExtensionLoaded_Params(
- const ViewMsg_ExtensionLoaded_Params& other);
-
- // Creates a new extension from the data in this object.
- scoped_refptr<Extension> ConvertToExtension() const;
-
- // The subset of the extension manifest data we send to renderers.
- scoped_ptr<DictionaryValue> manifest;
-
- // The location the extension was installed from.
- Extension::Location location;
-
- // The path the extension was loaded from. This is used in the renderer only
- // to generate the extension ID for extensions that are loaded unpacked.
- FilePath path;
-
- // We keep this separate so that it can be used in logging.
- std::string id;
-};
-
-// Parameters structure for ViewHostMsg_ExtensionRequest.
-struct ViewHostMsg_DomMessage_Params {
- ViewHostMsg_DomMessage_Params();
- ~ViewHostMsg_DomMessage_Params();
-
- // Message name.
- std::string name;
-
- // List of message arguments.
- ListValue arguments;
-
- // URL of the frame request was sent from.
- GURL source_url;
-
- // Unique request id to match requests and responses.
- int request_id;
-
- // True if request has a callback specified.
- bool has_callback;
-
- // True if request is executed in response to an explicit user gesture.
- bool user_gesture;
-};
-
namespace IPC {
class Message;
@@ -200,30 +115,6 @@
static void Log(const param_type& p, std::string* l);
};
-template <>
-struct ParamTraits<ViewMsg_ExecuteCode_Params> {
- typedef ViewMsg_ExecuteCode_Params param_type;
- static void Write(Message* m, const param_type& p);
- static bool Read(const Message* m, void** iter, param_type* p);
- static void Log(const param_type& p, std::string* l);
-};
-
-template <>
-struct ParamTraits<ViewMsg_ExtensionLoaded_Params> {
- typedef ViewMsg_ExtensionLoaded_Params param_type;
- static void Write(Message* m, const param_type& p);
- static bool Read(const Message* m, void** iter, param_type* p);
- static void Log(const param_type& p, std::string* l);
-};
-
-template <>
-struct ParamTraits<ViewHostMsg_DomMessage_Params> {
- typedef ViewHostMsg_DomMessage_Params param_type;
- static void Write(Message* m, const param_type& p);
- static bool Read(const Message* m, void** iter, param_type* p);
- static void Log(const param_type& p, std::string* l);
-};
-
} // namespace IPC
#endif // CHROME_COMMON_RENDER_MESSAGES_PARAMS_H_
« no previous file with comments | « chrome/common/render_messages.cc ('k') | chrome/common/render_messages_params.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698