| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 CHROME_BROWSER_PRERENDER_PRERENDER_CONTENTS_H_ | 5 #ifndef CHROME_BROWSER_PRERENDER_PRERENDER_CONTENTS_H_ |
| 6 #define CHROME_BROWSER_PRERENDER_PRERENDER_CONTENTS_H_ | 6 #define CHROME_BROWSER_PRERENDER_PRERENDER_CONTENTS_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 201 const GURL& prerender_url() const { return prerender_url_; } | 201 const GURL& prerender_url() const { return prerender_url_; } |
| 202 | 202 |
| 203 private: | 203 private: |
| 204 // Needs to be able to call the constructor. | 204 // Needs to be able to call the constructor. |
| 205 friend class PrerenderContentsFactoryImpl; | 205 friend class PrerenderContentsFactoryImpl; |
| 206 | 206 |
| 207 // Message handlers. | 207 // Message handlers. |
| 208 void OnDidStartProvisionalLoadForFrame(int64 frame_id, | 208 void OnDidStartProvisionalLoadForFrame(int64 frame_id, |
| 209 bool main_frame, | 209 bool main_frame, |
| 210 const GURL& url); | 210 const GURL& url); |
| 211 void OnDidRedirectProvisionalLoad(int32 page_id, | |
| 212 const GURL& source_url, | |
| 213 const GURL& target_url); | |
| 214 | 211 |
| 215 void OnUpdateFaviconURL(int32 page_id, const std::vector<FaviconURL>& urls); | 212 void OnUpdateFaviconURL(int32 page_id, const std::vector<FaviconURL>& urls); |
| 216 | 213 |
| 217 void OnMaybeCancelPrerender(PrerenderCancellationReason reason); | 214 void OnMaybeCancelPrerender(PrerenderCancellationReason reason); |
| 218 | 215 |
| 219 // Adds an alias URL, for one of the many redirections. Returns whether | 216 // Adds an alias URL, for one of the many redirections. Returns whether |
| 220 // the URL is valid. | 217 // the URL is valid. |
| 221 bool AddAliasURL(const GURL& url); | 218 bool AddAliasURL(const GURL& url); |
| 222 | 219 |
| 223 // Remove |this| from the PrerenderManager, set a final status, and | 220 // Remove |this| from the PrerenderManager, set a final status, and |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 282 // Maximum amount of private memory that may be used per PrerenderContents, | 279 // Maximum amount of private memory that may be used per PrerenderContents, |
| 283 // in MB. | 280 // in MB. |
| 284 static const int kMaxPrerenderPrivateMB = 100; | 281 static const int kMaxPrerenderPrivateMB = 100; |
| 285 | 282 |
| 286 DISALLOW_COPY_AND_ASSIGN(PrerenderContents); | 283 DISALLOW_COPY_AND_ASSIGN(PrerenderContents); |
| 287 }; | 284 }; |
| 288 | 285 |
| 289 } // prerender | 286 } // prerender |
| 290 | 287 |
| 291 #endif // CHROME_BROWSER_PRERENDER_PRERENDER_CONTENTS_H_ | 288 #endif // CHROME_BROWSER_PRERENDER_PRERENDER_CONTENTS_H_ |
| OLD | NEW |