Chromium Code Reviews| Index: chrome/browser/memory/tab_manager.h |
| diff --git a/chrome/browser/memory/tab_manager.h b/chrome/browser/memory/tab_manager.h |
| index 1196c08dcdf5d62b2ae05634b0ef3f88caa58292..05c631a7014a653058ac51190e853803ae5b9a28 100644 |
| --- a/chrome/browser/memory/tab_manager.h |
| +++ b/chrome/browser/memory/tab_manager.h |
| @@ -159,6 +159,9 @@ class TabManager : public TabStripModelObserver { |
| static int64_t IdFromWebContents(content::WebContents* web_contents); |
| private: |
| + FRIEND_TEST_ALL_PREFIXES(TabManagerTest, |
| + ActivateTabResetPurgeAndSuspendState); |
| + FRIEND_TEST_ALL_PREFIXES(TabManagerTest, NextPurgeAndSuspendState); |
| FRIEND_TEST_ALL_PREFIXES(TabManagerTest, AutoDiscardable); |
| FRIEND_TEST_ALL_PREFIXES(TabManagerTest, CanOnlyDiscardOnce); |
| FRIEND_TEST_ALL_PREFIXES(TabManagerTest, ChildProcessNotifications); |
| @@ -270,6 +273,14 @@ class TabManager : public TabStripModelObserver { |
| RESUMED, |
| SUSPENDED, |
| }; |
| + // Returns WebContents whose contents id matches the given tab-contents-id. |
|
chrisha
2016/11/01 21:22:56
|tab_contents_id|
tasak
2016/11/02 04:19:46
Done.
|
| + content::WebContents* GetWebContentsById(int64_t tab_contents_id); |
| + |
| + // Returns the next state of the purge and suspend. |
|
chrisha
2016/11/01 21:22:56
This comment isn't very illuminating. What is |pur
tasak
2016/11/02 04:19:46
I renamed purge_and_suspend_threshold. Now it is t
|
| + PurgeAndSuspendState GetNextPurgeAndSuspendState( |
| + content::WebContents* content, |
| + const base::TimeTicks& current_time, |
|
chrisha
2016/11/01 21:22:56
TimeTicks are overwhelmingly passed by value in Ch
tasak
2016/11/02 04:19:46
Done.
|
| + const base::TimeDelta& purge_and_suspend_threshold) const; |
| // Purges and suspends renderers in backgrounded tabs. |
| void PurgeAndSuspendBackgroundedTabs(); |