Chromium Code Reviews| Index: extensions/browser/guest_view/web_view/web_view_guest.cc |
| diff --git a/extensions/browser/guest_view/web_view/web_view_guest.cc b/extensions/browser/guest_view/web_view/web_view_guest.cc |
| index da15b9fa92d4571d3a5dc28e216887b8c6b37452..15dacf4893a80bc2ba5f31b1d8fff341841991f6 100644 |
| --- a/extensions/browser/guest_view/web_view/web_view_guest.cc |
| +++ b/extensions/browser/guest_view/web_view/web_view_guest.cc |
| @@ -48,6 +48,7 @@ |
| #include "extensions/browser/guest_view/web_view/web_view_renderer_state.h" |
| #include "extensions/common/constants.h" |
| #include "extensions/common/extension_messages.h" |
| +#include "extensions/common/manifest_constants.h" |
| #include "extensions/strings/grit/extensions_strings.h" |
| #include "ipc/ipc_message_macros.h" |
| #include "net/base/escape.h" |
| @@ -58,6 +59,7 @@ |
| using base::UserMetricsAction; |
| using content::GlobalRequestID; |
| using content::RenderFrameHost; |
| +using content::RenderProcessHost; |
| using content::ResourceType; |
| using content::StoragePartition; |
| using content::WebContents; |
| @@ -264,6 +266,18 @@ bool WebViewGuest::GetGuestPartitionConfigForSite( |
| } |
| // static |
| +std::string WebViewGuest::GetPartitionID( |
| + const RenderProcessHost* render_process_host) { |
| + WebViewRendererState* renderer_state = WebViewRendererState::GetInstance(); |
| + int process_id = render_process_host->GetID(); |
| + std::string partition_id; |
| + if (renderer_state->IsGuest(process_id)) |
| + renderer_state->GetPartitionID(process_id, &partition_id); |
|
not at google - send to devlin
2015/08/31 18:31:44
There is a threading mismatch here. WebViewRendere
paulmeyer
2015/08/31 21:40:08
You may have been looking at an out-of-date versio
not at google - send to devlin
2015/08/31 21:52:51
I'm not looking at an old version, I'm looking at
paulmeyer
2015/09/02 13:43:57
Oh, I see. Those comments are stale, so I'll remov
|
| + |
| + return partition_id; |
| +} |
| + |
| +// static |
| const char WebViewGuest::Type[] = "webview"; |
| // static |