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

Unified Diff: content/browser/renderer_host/render_process_host_impl.h

Issue 2387603003: Resume a backgrounded renderer that was purged and suspended (Closed)
Patch Set: Add Resume Created 4 years, 3 months 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
Index: content/browser/renderer_host/render_process_host_impl.h
diff --git a/content/browser/renderer_host/render_process_host_impl.h b/content/browser/renderer_host/render_process_host_impl.h
index 6e6a0f27ced9be3c8d4d09c5f1aa72e5800bc035..4327ab0d8109d7518e9876999118fce3edb256ef 100644
--- a/content/browser/renderer_host/render_process_host_impl.h
+++ b/content/browser/renderer_host/render_process_host_impl.h
@@ -179,6 +179,9 @@ class CONTENT_EXPORT RenderProcessHostImpl
void ForceReleaseWorkerRefCounts() override;
bool IsWorkerRefCountDisabled() override;
void PurgeAndSuspend() override;
+ void Resume() override;
+ const base::TimeTicks& GetLastPurgedAndSuspendedTime() const override;
+ const base::TimeTicks& GetLastResumedTime() const override;
mojom::RouteProvider* GetRemoteRouteProvider();
@@ -477,6 +480,12 @@ class CONTENT_EXPORT RenderProcessHostImpl
// Stores the time at which the first call to Init happened.
base::TimeTicks init_time_;
+ // The last time when the renderer is purged and suspended.
+ base::TimeTicks last_purged_and_suspended_time_;
+
+ // The last time when the renderer is resumed from suspended.
+ base::TimeTicks last_resumed_time_;
+
// Used to launch and terminate the process without blocking the UI thread.
std::unique_ptr<ChildProcessLauncher> child_process_launcher_;

Powered by Google App Engine
This is Rietveld 408576698