OLD | NEW |
---|---|
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CONTENT_BROWSER_FRAME_HOST_NAVIGATION_ENTRY_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_FRAME_HOST_NAVIGATION_ENTRY_IMPL_H_ |
6 #define CONTENT_BROWSER_FRAME_HOST_NAVIGATION_ENTRY_IMPL_H_ | 6 #define CONTENT_BROWSER_FRAME_HOST_NAVIGATION_ENTRY_IMPL_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
10 #include "base/memory/scoped_vector.h" | 10 #include "base/memory/scoped_vector.h" |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
75 bool is_renderer_initiated); | 75 bool is_renderer_initiated); |
76 ~NavigationEntryImpl() override; | 76 ~NavigationEntryImpl() override; |
77 | 77 |
78 // NavigationEntry implementation: | 78 // NavigationEntry implementation: |
79 int GetUniqueID() const override; | 79 int GetUniqueID() const override; |
80 PageType GetPageType() const override; | 80 PageType GetPageType() const override; |
81 void SetURL(const GURL& url) override; | 81 void SetURL(const GURL& url) override; |
82 const GURL& GetURL() const override; | 82 const GURL& GetURL() const override; |
83 void SetBaseURLForDataURL(const GURL& url) override; | 83 void SetBaseURLForDataURL(const GURL& url) override; |
84 const GURL& GetBaseURLForDataURL() const override; | 84 const GURL& GetBaseURLForDataURL() const override; |
85 void SetDataURLAsString(const std::string& url) override; | |
Charlie Reis
2015/12/10 20:43:46
boliu@ and I spent a lot of time avoiding a new me
mnaganov (inactive)
2015/12/11 23:14:23
I hope I added enough checks to enforce consistenc
| |
86 const std::string& GetDataURLAsString() const override; | |
85 void SetReferrer(const Referrer& referrer) override; | 87 void SetReferrer(const Referrer& referrer) override; |
86 const Referrer& GetReferrer() const override; | 88 const Referrer& GetReferrer() const override; |
87 void SetVirtualURL(const GURL& url) override; | 89 void SetVirtualURL(const GURL& url) override; |
88 const GURL& GetVirtualURL() const override; | 90 const GURL& GetVirtualURL() const override; |
89 void SetTitle(const base::string16& title) override; | 91 void SetTitle(const base::string16& title) override; |
90 const base::string16& GetTitle() const override; | 92 const base::string16& GetTitle() const override; |
91 void SetPageState(const PageState& state) override; | 93 void SetPageState(const PageState& state) override; |
92 PageState GetPageState() const override; | 94 PageState GetPageState() const override; |
93 void SetPageID(int page_id) override; | 95 void SetPageID(int page_id) override; |
94 int32 GetPageID() const override; | 96 int32 GetPageID() const override; |
(...skipping 318 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
413 // This member is not persisted with session restore. | 415 // This member is not persisted with session restore. |
414 std::string extra_headers_; | 416 std::string extra_headers_; |
415 | 417 |
416 // This member is cleared in |ResetForCommit| and not persisted. | 418 // This member is cleared in |ResetForCommit| and not persisted. |
417 scoped_refptr<SiteInstanceImpl> source_site_instance_; | 419 scoped_refptr<SiteInstanceImpl> source_site_instance_; |
418 | 420 |
419 // Used for specifying base URL for pages loaded via data URLs. Only used and | 421 // Used for specifying base URL for pages loaded via data URLs. Only used and |
420 // persisted by Android WebView. | 422 // persisted by Android WebView. |
421 GURL base_url_for_data_url_; | 423 GURL base_url_for_data_url_; |
422 | 424 |
425 // Used for passing really big data URLs from browser to renderers. Only used | |
426 // and persisted by Android WebView. | |
Charlie Reis
2015/12/10 20:43:46
I'm concerned about the "only Android WebView" com
mnaganov (inactive)
2015/12/11 23:14:23
Now it's enforced by OS_ANDROID defines.
| |
427 std::string data_url_as_string_; | |
Charlie Reis
2015/12/10 20:43:46
I'd like to consider alternatives to this if we ca
mnaganov (inactive)
2015/12/11 23:14:23
Considered.
| |
428 | |
423 // Whether the entry, while loading, was created for a renderer-initiated | 429 // Whether the entry, while loading, was created for a renderer-initiated |
424 // navigation. This dictates whether the URL should be displayed before the | 430 // navigation. This dictates whether the URL should be displayed before the |
425 // navigation commits. It is cleared in |ResetForCommit| and not persisted. | 431 // navigation commits. It is cleared in |ResetForCommit| and not persisted. |
426 bool is_renderer_initiated_; | 432 bool is_renderer_initiated_; |
427 | 433 |
428 // This is a cached version of the result of GetTitleForDisplay. It prevents | 434 // This is a cached version of the result of GetTitleForDisplay. It prevents |
429 // us from having to do URL formatting on the URL every time the title is | 435 // us from having to do URL formatting on the URL every time the title is |
430 // displayed. When the URL, virtual URL, or title is set, this should be | 436 // displayed. When the URL, virtual URL, or title is set, this should be |
431 // cleared to force a refresh. | 437 // cleared to force a refresh. |
432 mutable base::string16 cached_display_title_; | 438 mutable base::string16 cached_display_title_; |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
488 // persisted, unless specific data is taken out/put back in at save/restore | 494 // persisted, unless specific data is taken out/put back in at save/restore |
489 // time (see TabNavigation for an example of this). | 495 // time (see TabNavigation for an example of this). |
490 std::map<std::string, base::string16> extra_data_; | 496 std::map<std::string, base::string16> extra_data_; |
491 | 497 |
492 DISALLOW_COPY_AND_ASSIGN(NavigationEntryImpl); | 498 DISALLOW_COPY_AND_ASSIGN(NavigationEntryImpl); |
493 }; | 499 }; |
494 | 500 |
495 } // namespace content | 501 } // namespace content |
496 | 502 |
497 #endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATION_ENTRY_IMPL_H_ | 503 #endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATION_ENTRY_IMPL_H_ |
OLD | NEW |