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

Unified Diff: chrome/common/render_messages.h

Issue 7990005: Use a placeholder instead of the default plugin for missing plug-ins on Mac and Linux. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix Created 9 years, 3 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/common/render_messages.h
diff --git a/chrome/common/render_messages.h b/chrome/common/render_messages.h
index 84d1cff5fbd0a6d204925d3f86921edcb64a0388..663379c5db92a89ebd95e6eb94137bae4069b39a 100644
--- a/chrome/common/render_messages.h
+++ b/chrome/common/render_messages.h
@@ -31,6 +31,7 @@
#include "third_party/WebKit/Source/WebKit/chromium/public/WebCache.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebConsoleMessage.h"
#include "ui/gfx/rect.h"
+#include "webkit/plugins/webplugininfo.h"
// Singly-included section for enums and custom IPC traits.
#ifndef CHROME_COMMON_RENDER_MESSAGES_H_
@@ -50,6 +51,16 @@ enum ViewHostMsg_JavaScriptStressTestControl_Commands {
kJavaScriptStressTestPrepareStressRun = 1,
};
+struct ChromeViewHostMsg_GetPluginInfo_Status {
+ // TODO(bauerb): Add more status values (blocked, click-to-play, out of date,
+ // requires authorization).
+ enum Value {
+ kAllowed,
+ kDisabled,
+ kNotFound,
+ };
+};
+
namespace IPC {
#if defined(OS_POSIX) && !defined(USE_AURA)
@@ -91,6 +102,7 @@ struct ParamTraits<ContentSettings> {
#define IPC_MESSAGE_START ChromeMsgStart
+IPC_ENUM_TRAITS(ChromeViewHostMsg_GetPluginInfo_Status::Value)
IPC_ENUM_TRAITS(InstantCompleteBehavior)
IPC_ENUM_TRAITS(search_provider::OSDDType)
IPC_ENUM_TRAITS(search_provider::InstallState)
@@ -127,6 +139,13 @@ IPC_STRUCT_TRAITS_BEGIN(WebKit::WebCache::UsageStats)
IPC_STRUCT_TRAITS_MEMBER(deadSize)
IPC_STRUCT_TRAITS_END()
+IPC_STRUCT_BEGIN(ChromeViewHostMsg_GetPluginInfo_Params)
jam 2011/09/30 17:01:21 nit: we normally don't create structs unless we ne
Bernhard Bauer 2011/09/30 17:22:21 I need to forward-declare the struct, and I can't
jam 2011/09/30 17:40:19 that's by design, since there's a lot of unnecessa
Bernhard Bauer 2011/10/05 13:34:33 I split up ChromeViewHostMsg_GetPluginInfo_Params
+ IPC_STRUCT_MEMBER(ChromeViewHostMsg_GetPluginInfo_Status::Value, status)
+ IPC_STRUCT_MEMBER(webkit::WebPluginInfo, plugin)
+ IPC_STRUCT_MEMBER(std::string, actual_mime_type)
+IPC_STRUCT_END()
+
+
//-----------------------------------------------------------------------------
// RenderView messages
// These are messages sent from the browser to the renderer process.
@@ -384,6 +403,17 @@ IPC_SYNC_MESSAGE_CONTROL2_1(ChromeViewHostMsg_GetPluginContentSetting,
std::string /* resource */,
ContentSetting /* setting */)
+// Return information about a plugin for the given URL and MIME type.
+// In contrast to ViewHostMsg_GetPluginInfo in content/, this IPC call knows
+// about specific reasons why a plug-in can't be used, for example because it's
+// disabled.
+IPC_SYNC_MESSAGE_CONTROL4_1(ChromeViewHostMsg_GetPluginInfo,
+ int /* render_view_id */,
+ GURL /* url */,
+ GURL /* top origin url */,
+ std::string /* mime_type */,
+ ChromeViewHostMsg_GetPluginInfo_Params /* params */)
+
// Specifies the URL as the first parameter (a wstring) and thumbnail as
// binary data as the second parameter.
IPC_MESSAGE_ROUTED3(ChromeViewHostMsg_Thumbnail,

Powered by Google App Engine
This is Rietveld 408576698