Commit d6e43818 authored by thestig's avatar thestig Committed by Commit Bot

Mark plugin requires restart code/resources Linux-only.

Review-Url: https://codereview.chromium.org/2910823002
Cr-Commit-Position: refs/heads/master@{#476477}
parent 279874b4
......@@ -1183,9 +1183,11 @@ Please check your email at <ph name="ACCOUNT_EMAIL">$2<ex>jane.doe@example.com</
</message>
<!-- Plugin Placeholders -->
<message name="IDS_PLUGIN_RESTART_REQUIRED" desc="The placeholder text for a plugin that can't be loaded until the browser is restarted.">
Restart Chromium to enable <ph name="PLUGIN_NAME">$1<ex>Flash</ex></ph>
</message>
<if expr="is_linux">
<message name="IDS_PLUGIN_RESTART_REQUIRED" desc="The placeholder text for a plugin that can't be loaded until the browser is restarted.">
Restart Chromium to enable <ph name="PLUGIN_NAME">$1<ex>Flash</ex></ph>
</message>
</if>
<!-- Desktop to iOS promotion -->
<message name="IDS_PASSWORD_MANAGER_DESKTOP_TO_IOS_PROMO_TEXT" desc="Text for Chrome iOS Promotion appearing in the password bubble after a password is saved.">
......
......@@ -1193,9 +1193,11 @@ Please check your email at <ph name="ACCOUNT_EMAIL">$2<ex>jane.doe@example.com</
</message>
<!-- Plugin Placeholders -->
<message name="IDS_PLUGIN_RESTART_REQUIRED" desc="The placeholder text for a plugin that can't be loaded until the browser is restarted.">
Restart Chrome to enable <ph name="PLUGIN_NAME">$1<ex>Flash</ex></ph>
</message>
<if expr="is_linux">
<message name="IDS_PLUGIN_RESTART_REQUIRED" desc="The placeholder text for a plugin that can't be loaded until the browser is restarted.">
Restart Chrome to enable <ph name="PLUGIN_NAME">$1<ex>Flash</ex></ph>
</message>
</if>
<!-- Desktop to iOS promotion -->
<message name="IDS_PASSWORD_MANAGER_DESKTOP_TO_IOS_PROMO_TEXT" desc="Text for Chrome iOS Promotion appearing in the password bubble after a password is saved.">
......
......@@ -11,6 +11,7 @@
#include <utility>
#include "base/bind.h"
#include "base/memory/ptr_util.h"
#include "base/memory/singleton.h"
#include "base/metrics/histogram_macros.h"
#include "base/strings/utf_string_conversions.h"
......@@ -497,10 +498,10 @@ void PluginInfoMessageFilter::ComponentPluginLookupDone(
output->status =
ChromeViewHostMsg_GetPluginInfo_Status::kRestartRequired;
}
#endif // defined(OS_LINUX)
plugin_metadata.reset(new PluginMetadata(
#endif
plugin_metadata = base::MakeUnique<PluginMetadata>(
cus_plugin_info->id, cus_plugin_info->name, false, GURL(), GURL(),
base::ASCIIToUTF16(cus_plugin_info->id), std::string()));
base::ASCIIToUTF16(cus_plugin_info->id), std::string());
}
GetPluginInfoReply(params, std::move(output), std::move(plugin_metadata),
reply_msg);
......
......@@ -55,7 +55,9 @@ enum class ChromeViewHostMsg_GetPluginInfo_Status {
kOutdatedBlocked,
kOutdatedDisallowed,
kPlayImportantContent,
#if defined(OS_LINUX)
kRestartRequired,
#endif
kUnauthorized,
};
......
......@@ -956,6 +956,7 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
identifier));
break;
}
#if defined(OS_LINUX)
case ChromeViewHostMsg_GetPluginInfo_Status::kRestartRequired: {
placeholder = create_blocked_plugin(
IDR_BLOCKED_PLUGIN_HTML,
......@@ -963,6 +964,7 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
group_name));
break;
}
#endif
}
}
placeholder->SetStatus(status);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment