OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CONTENT_PUBLIC_BROWSER_RENDER_PROCESS_HOST_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_RENDER_PROCESS_HOST_H_ |
6 #define CONTENT_PUBLIC_BROWSER_RENDER_PROCESS_HOST_H_ | 6 #define CONTENT_PUBLIC_BROWSER_RENDER_PROCESS_HOST_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
(...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
293 #endif | 293 #endif |
294 | 294 |
295 // Returns true if this process currently has backgrounded priority. | 295 // Returns true if this process currently has backgrounded priority. |
296 virtual bool IsProcessBackgrounded() const = 0; | 296 virtual bool IsProcessBackgrounded() const = 0; |
297 | 297 |
298 // Called when the existence of the other renderer process which is connected | 298 // Called when the existence of the other renderer process which is connected |
299 // to the Worker in this renderer process has changed. | 299 // to the Worker in this renderer process has changed. |
300 virtual void IncrementWorkerRefCount() = 0; | 300 virtual void IncrementWorkerRefCount() = 0; |
301 virtual void DecrementWorkerRefCount() = 0; | 301 virtual void DecrementWorkerRefCount() = 0; |
302 | 302 |
| 303 // Purges and suspends the renderer process. |
| 304 virtual void PurgeAndSuspend() = 0; |
| 305 |
303 // Returns the current number of active views in this process. Excludes | 306 // Returns the current number of active views in this process. Excludes |
304 // any RenderViewHosts that are swapped out. | 307 // any RenderViewHosts that are swapped out. |
305 size_t GetActiveViewCount(); | 308 size_t GetActiveViewCount(); |
306 | 309 |
307 // Static management functions ----------------------------------------------- | 310 // Static management functions ----------------------------------------------- |
308 | 311 |
309 // Flag to run the renderer in process. This is primarily | 312 // Flag to run the renderer in process. This is primarily |
310 // for debugging purposes. When running "in process", the | 313 // for debugging purposes. When running "in process", the |
311 // browser maintains a single RenderProcessHost which communicates | 314 // browser maintains a single RenderProcessHost which communicates |
312 // to a RenderProcess which is instantiated in the same process | 315 // to a RenderProcess which is instantiated in the same process |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
355 static void SetMaxRendererProcessCount(size_t count); | 358 static void SetMaxRendererProcessCount(size_t count); |
356 | 359 |
357 // Returns the current maximum number of renderer process hosts kept by the | 360 // Returns the current maximum number of renderer process hosts kept by the |
358 // content module. | 361 // content module. |
359 static size_t GetMaxRendererProcessCount(); | 362 static size_t GetMaxRendererProcessCount(); |
360 }; | 363 }; |
361 | 364 |
362 } // namespace content. | 365 } // namespace content. |
363 | 366 |
364 #endif // CONTENT_PUBLIC_BROWSER_RENDER_PROCESS_HOST_H_ | 367 #endif // CONTENT_PUBLIC_BROWSER_RENDER_PROCESS_HOST_H_ |
OLD | NEW |