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

Unified Diff: chrome/renderer/chrome_render_thread_observer.h

Issue 2531133002: Convert SetIsIncognitoProcess to use mojo. (Closed)
Patch Set: Convert SetIsIncognitoProcess to use mojo. Created 4 years 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/renderer_configuration.mojom ('k') | chrome/renderer/chrome_render_thread_observer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/chrome_render_thread_observer.h
diff --git a/chrome/renderer/chrome_render_thread_observer.h b/chrome/renderer/chrome_render_thread_observer.h
index 0549d020ebcf6a98fdd84ae54e6ac4381236617b..8d1cceb7ce18312018d856c891805fbaecbf55f1 100644
--- a/chrome/renderer/chrome_render_thread_observer.h
+++ b/chrome/renderer/chrome_render_thread_observer.h
@@ -12,9 +12,11 @@
#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/metrics/field_trial.h"
+#include "chrome/common/renderer_configuration.mojom.h"
#include "components/content_settings/core/common/content_settings.h"
#include "components/variations/child_process_field_trial_syncer.h"
#include "content/public/renderer/render_thread_observer.h"
+#include "mojo/public/cpp/bindings/associated_binding.h"
namespace content {
class ResourceDispatcherDelegate;
@@ -29,7 +31,8 @@ class VisitedLinkSlave;
// happen. If a few messages are related, they should probably have their own
// observer.
class ChromeRenderThreadObserver : public content::RenderThreadObserver,
- public base::FieldTrialList::Observer {
+ public base::FieldTrialList::Observer,
+ public chrome::mojom::RendererConfiguration {
public:
ChromeRenderThreadObserver();
~ChromeRenderThreadObserver() override;
@@ -46,6 +49,10 @@ class ChromeRenderThreadObserver : public content::RenderThreadObserver,
private:
// content::RenderThreadObserver:
+ void RegisterMojoInterfaces(
+ content::AssociatedInterfaceRegistry* associated_interfaces) override;
+ void UnregisterMojoInterfaces(
+ content::AssociatedInterfaceRegistry* associated_interfaces) override;
bool OnControlMessageReceived(const IPC::Message& message) override;
void OnRenderProcessShutdown() override;
@@ -53,7 +60,12 @@ class ChromeRenderThreadObserver : public content::RenderThreadObserver,
void OnFieldTrialGroupFinalized(const std::string& trial_name,
const std::string& group_name) override;
- void OnSetIsIncognitoProcess(bool is_incognito_process);
+ // chrome::mojom::RendererConfiguration:
+ void SetInitialConfiguration(bool is_incognito_process) override;
+
+ void OnRendererInterfaceRequest(
+ chrome::mojom::RendererConfigurationAssociatedRequest request);
+
void OnSetContentSettingRules(const RendererContentSettingRules& rules);
void OnSetFieldTrialGroup(const std::string& trial_name,
const std::string& group_name);
@@ -65,6 +77,9 @@ class ChromeRenderThreadObserver : public content::RenderThreadObserver,
std::unique_ptr<visitedlink::VisitedLinkSlave> visited_link_slave_;
+ mojo::AssociatedBinding<chrome::mojom::RendererConfiguration>
+ renderer_configuration_binding_;
+
base::WeakPtrFactory<ChromeRenderThreadObserver> weak_factory_;
DISALLOW_COPY_AND_ASSIGN(ChromeRenderThreadObserver);
« no previous file with comments | « chrome/common/renderer_configuration.mojom ('k') | chrome/renderer/chrome_render_thread_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698