| OLD | NEW |
| (Empty) | |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CHROME_RENDERER_CHROME_RENDER_PROCESS_OBSERVER_H_ |
| 6 #define CHROME_RENDERER_CHROME_RENDER_PROCESS_OBSERVER_H_ |
| 7 #pragma once |
| 8 |
| 9 #include "base/compiler_specific.h" |
| 10 #include "content/renderer/render_process_observer.h" |
| 11 |
| 12 class GURL; |
| 13 struct ContentSettings; |
| 14 |
| 15 // This class filters the incoming control messages (i.e. ones not destined for |
| 16 // a RenderView) for Chrome specific messages that the content layer doesn't |
| 17 // happen. If a few messages are related, they should probably have their own |
| 18 // observer. |
| 19 class ChromeRenderProcessObserver : public RenderProcessObserver { |
| 20 public: |
| 21 ChromeRenderProcessObserver(); |
| 22 virtual ~ChromeRenderProcessObserver(); |
| 23 |
| 24 static bool is_incognito_process() { return is_incognito_process_; } |
| 25 |
| 26 private: |
| 27 // RenderProcessObserver implementation. |
| 28 virtual bool OnControlMessageReceived(const IPC::Message& message) OVERRIDE; |
| 29 |
| 30 void OnSetIsIncognitoProcess(bool is_incognito_process); |
| 31 void OnSetContentSettingsForCurrentURL( |
| 32 const GURL& url, const ContentSettings& content_settings); |
| 33 void OnSetCacheCapacities(size_t min_dead_capacity, |
| 34 size_t max_dead_capacity, |
| 35 size_t capacity); |
| 36 void OnClearCache(); |
| 37 void OnGetCacheResourceStats(); |
| 38 void OnGetRendererTcmalloc(); |
| 39 void OnGetV8HeapStats(); |
| 40 void OnPurgeMemory(); |
| 41 |
| 42 static bool is_incognito_process_; |
| 43 |
| 44 DISALLOW_COPY_AND_ASSIGN(ChromeRenderProcessObserver); |
| 45 }; |
| 46 |
| 47 #endif // CHROME_RENDERER_CHROME_RENDER_PROCESS_OBSERVER_H_ |
| OLD | NEW |