Chromium Code Reviews| Index: chrome/browser/prerender/prerender_manager.h |
| diff --git a/chrome/browser/prerender/prerender_manager.h b/chrome/browser/prerender/prerender_manager.h |
| index abd1541dc3366309fcb2b930c7239cea6e598fec..8c086a1ec60cc1c0445a78ebd15201aa98ed3882 100644 |
| --- a/chrome/browser/prerender/prerender_manager.h |
| +++ b/chrome/browser/prerender/prerender_manager.h |
| @@ -101,8 +101,12 @@ class PrerenderManager : public base::SupportsWeakPtr<PrerenderManager>, |
| // Adds a prerender for |url| if valid. As the prerender request is coming |
| // from a source without a RenderViewHost (i.e., the omnibox) we don't have a |
| // child or route id, or a referrer. This method uses sensible values for |
| - // those. |
| - bool AddPrerenderFromOmnibox(const GURL& url); |
| + // those. The |session_storage_namespace| can be determined at this time, |
| + // however, because it is based off of the destination tab rather than the |
| + // current contents. |
|
mmenke
2011/11/02 02:27:55
"Destination tab rather than the current contents"
cbentzel
2011/11/02 15:57:08
Fixed comment - thanks for pointing this out.
|
| + bool AddPrerenderFromOmnibox( |
| + const GURL& url, |
| + SessionStorageNamespace* session_storage_namespace); |
| // Destroy all prerenders for the given child route id pair and assign a final |
| // status to them. |
| @@ -245,12 +249,15 @@ class PrerenderManager : public base::SupportsWeakPtr<PrerenderManager>, |
| // Adds a prerender for |url| from referrer |referrer| initiated from the |
| // RenderViewHost specified by |child_route_id_pair|. The |origin| specifies |
| - // how the prerender was added. |
| + // how the prerender was added. If the |session_storage_namespace| is NULL, |
| + // it is discovered using the RenderViewHost specified by |
| + // |child_route_id_pair|. |
| bool AddPrerender( |
| Origin origin, |
| const std::pair<int, int>& child_route_id_pair, |
| const GURL& url, |
| - const GURL& referrer); |
| + const GURL& referrer, |
| + SessionStorageNamespace* session_storage_namespace); |
| // Adds a pending preload issued by the prerendering RenderView identified by |
| // |child_route_id_pair|. If and when that prerendering RenderView is used, |
| @@ -293,10 +300,12 @@ class PrerenderManager : public base::SupportsWeakPtr<PrerenderManager>, |
| void DeleteOldEntries(); |
| virtual base::Time GetCurrentTime() const; |
| virtual base::TimeTicks GetCurrentTimeTicks() const; |
| - virtual PrerenderContents* CreatePrerenderContents(const GURL& url, |
| - const GURL& referrer, |
| - Origin origin, |
| - uint8 experiment_id); |
| + virtual PrerenderContents* CreatePrerenderContents( |
| + SessionStorageNamespace* session_storage_namespace, |
| + const GURL& url, |
| + const GURL& referrer, |
| + Origin origin, |
| + uint8 experiment_id); |
| // Checks if the PrerenderContents has been added to the pending delete list. |
| bool IsPendingDelete(PrerenderContents* entry) const; |