| 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 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 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <utility> | 9 #include <utility> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 335 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 346 content::NotificationRegistrar& notification_registrar() { | 346 content::NotificationRegistrar& notification_registrar() { |
| 347 return notification_registrar_; | 347 return notification_registrar_; |
| 348 } | 348 } |
| 349 | 349 |
| 350 size_t pending_prerender_count() const; | 350 size_t pending_prerender_count() const; |
| 351 | 351 |
| 352 bool prerendering_has_been_cancelled() const { | 352 bool prerendering_has_been_cancelled() const { |
| 353 return prerendering_has_been_cancelled_; | 353 return prerendering_has_been_cancelled_; |
| 354 } | 354 } |
| 355 | 355 |
| 356 virtual content::WebContents* CreateWebContents( | 356 content::WebContents* CreateWebContents( |
| 357 content::SessionStorageNamespace* session_storage_namespace); | 357 content::SessionStorageNamespace* session_storage_namespace); |
| 358 | 358 |
| 359 bool prerendering_has_started_; | 359 bool prerendering_has_started_; |
| 360 | 360 |
| 361 // Time at which we started to load the URL. This is used to compute | 361 // Time at which we started to load the URL. This is used to compute |
| 362 // the time elapsed from initiating a prerender until the time the | 362 // the time elapsed from initiating a prerender until the time the |
| 363 // (potentially only partially) prerendered page is shown to the user. | 363 // (potentially only partially) prerendered page is shown to the user. |
| 364 base::TimeTicks load_start_time_; | 364 base::TimeTicks load_start_time_; |
| 365 | 365 |
| 366 // The prerendered WebContents; may be null. | 366 // The prerendered WebContents; may be null. |
| (...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 477 // Resources that are throttled, pending a prerender use. Can only access a | 477 // Resources that are throttled, pending a prerender use. Can only access a |
| 478 // throttle on the IO thread. | 478 // throttle on the IO thread. |
| 479 std::vector<base::WeakPtr<PrerenderResourceThrottle> > resource_throttles_; | 479 std::vector<base::WeakPtr<PrerenderResourceThrottle> > resource_throttles_; |
| 480 | 480 |
| 481 DISALLOW_COPY_AND_ASSIGN(PrerenderContents); | 481 DISALLOW_COPY_AND_ASSIGN(PrerenderContents); |
| 482 }; | 482 }; |
| 483 | 483 |
| 484 } // namespace prerender | 484 } // namespace prerender |
| 485 | 485 |
| 486 #endif // CHROME_BROWSER_PRERENDER_PRERENDER_CONTENTS_H_ | 486 #endif // CHROME_BROWSER_PRERENDER_PRERENDER_CONTENTS_H_ |
| OLD | NEW |