| 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 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 113 // If |crash_report_mode| is GENERATE_CRASH_DUMP, then a browser crash dump | 113 // If |crash_report_mode| is GENERATE_CRASH_DUMP, then a browser crash dump |
| 114 // will be reported as well. | 114 // will be reported as well. |
| 115 virtual void ShutdownForBadMessage(CrashReportMode crash_report_mode) = 0; | 115 virtual void ShutdownForBadMessage(CrashReportMode crash_report_mode) = 0; |
| 116 | 116 |
| 117 // Track the count of visible widgets. Called by listeners to register and | 117 // Track the count of visible widgets. Called by listeners to register and |
| 118 // unregister visibility. | 118 // unregister visibility. |
| 119 virtual void WidgetRestored() = 0; | 119 virtual void WidgetRestored() = 0; |
| 120 virtual void WidgetHidden() = 0; | 120 virtual void WidgetHidden() = 0; |
| 121 virtual int VisibleWidgetCount() const = 0; | 121 virtual int VisibleWidgetCount() const = 0; |
| 122 | 122 |
| 123 // Called when the audio state changes for this render process host. | 123 // Called when an audio stream is added or removed and used to determine if |
| 124 virtual void AudioStateChanged() = 0; | 124 // the process should be backgrounded or not. |
| 125 virtual void OnAudioStreamAdded() = 0; |
| 126 virtual void OnAudioStreamRemoved() = 0; |
| 125 | 127 |
| 126 // Indicates whether the current RenderProcessHost is exclusively hosting | 128 // Indicates whether the current RenderProcessHost is exclusively hosting |
| 127 // guest RenderFrames. Not all guest RenderFrames are created equal. A guest, | 129 // guest RenderFrames. Not all guest RenderFrames are created equal. A guest, |
| 128 // as indicated by BrowserPluginGuest::IsGuest, may coexist with other | 130 // as indicated by BrowserPluginGuest::IsGuest, may coexist with other |
| 129 // non-guest RenderFrames in the same process if IsForGuestsOnly() is false. | 131 // non-guest RenderFrames in the same process if IsForGuestsOnly() is false. |
| 130 virtual bool IsForGuestsOnly() const = 0; | 132 virtual bool IsForGuestsOnly() const = 0; |
| 131 | 133 |
| 132 // Returns the storage partition associated with this process. | 134 // Returns the storage partition associated with this process. |
| 133 virtual StoragePartition* GetStoragePartition() const = 0; | 135 virtual StoragePartition* GetStoragePartition() const = 0; |
| 134 | 136 |
| (...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 408 static void SetMaxRendererProcessCount(size_t count); | 410 static void SetMaxRendererProcessCount(size_t count); |
| 409 | 411 |
| 410 // Returns the current maximum number of renderer process hosts kept by the | 412 // Returns the current maximum number of renderer process hosts kept by the |
| 411 // content module. | 413 // content module. |
| 412 static size_t GetMaxRendererProcessCount(); | 414 static size_t GetMaxRendererProcessCount(); |
| 413 }; | 415 }; |
| 414 | 416 |
| 415 } // namespace content. | 417 } // namespace content. |
| 416 | 418 |
| 417 #endif // CONTENT_PUBLIC_BROWSER_RENDER_PROCESS_HOST_H_ | 419 #endif // CONTENT_PUBLIC_BROWSER_RENDER_PROCESS_HOST_H_ |
| OLD | NEW |