Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(311)

Side by Side Diff: content/public/browser/web_contents.h

Issue 1947263004: Introduces a new MHTML generation parameter specifying different behvaior for cache-control headers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Work on compile. Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_H_
6 #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_H_ 6 #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <set> 10 #include <set>
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 class InterstitialPage; 53 class InterstitialPage;
54 class PageState; 54 class PageState;
55 class RenderFrameHost; 55 class RenderFrameHost;
56 class RenderProcessHost; 56 class RenderProcessHost;
57 class RenderViewHost; 57 class RenderViewHost;
58 class RenderWidgetHostView; 58 class RenderWidgetHostView;
59 class WebContentsDelegate; 59 class WebContentsDelegate;
60 struct CustomContextMenuContext; 60 struct CustomContextMenuContext;
61 struct DropData; 61 struct DropData;
62 struct Manifest; 62 struct Manifest;
63 struct MHTMLGenerationParams;
63 struct PageImportanceSignals; 64 struct PageImportanceSignals;
64 struct RendererPreferences; 65 struct RendererPreferences;
65 66
66 // WebContents is the core class in content/. A WebContents renders web content 67 // WebContents is the core class in content/. A WebContents renders web content
67 // (usually HTML) in a rectangular area. 68 // (usually HTML) in a rectangular area.
68 // 69 //
69 // Instantiating one is simple: 70 // Instantiating one is simple:
70 // std::unique_ptr<content::WebContents> web_contents( 71 // std::unique_ptr<content::WebContents> web_contents(
71 // content::WebContents::Create( 72 // content::WebContents::Create(
72 // content::WebContents::CreateParams(browser_context))); 73 // content::WebContents::CreateParams(browser_context)));
(...skipping 471 matching lines...) Expand 10 before | Expand all | Expand 10 after
544 virtual void SaveFrameWithHeaders(const GURL& url, 545 virtual void SaveFrameWithHeaders(const GURL& url,
545 const Referrer& referrer, 546 const Referrer& referrer,
546 const std::string& headers) = 0; 547 const std::string& headers) = 0;
547 548
548 // Generate an MHTML representation of the current page in the given file. 549 // Generate an MHTML representation of the current page in the given file.
549 // If |use_binary_encoding| is specified, a Content-Transfer-Encoding value of 550 // If |use_binary_encoding| is specified, a Content-Transfer-Encoding value of
550 // 'binary' will be used, instead of a combination of 'quoted-printable' and 551 // 'binary' will be used, instead of a combination of 'quoted-printable' and
551 // 'base64'. Binary encoding is known to have interoperability issues and is 552 // 'base64'. Binary encoding is known to have interoperability issues and is
552 // not the recommended encoding for shareable content. 553 // not the recommended encoding for shareable content.
553 virtual void GenerateMHTML( 554 virtual void GenerateMHTML(
554 const base::FilePath& file, 555 const MHTMLGenerationParams& params,
555 bool use_binary_encoding,
556 const base::Callback<void(int64_t /* size of the file */)>& callback) = 0; 556 const base::Callback<void(int64_t /* size of the file */)>& callback) = 0;
557 557
558 // Returns the contents MIME type after a navigation. 558 // Returns the contents MIME type after a navigation.
559 virtual const std::string& GetContentsMimeType() const = 0; 559 virtual const std::string& GetContentsMimeType() const = 0;
560 560
561 // Returns true if this WebContents will notify about disconnection. 561 // Returns true if this WebContents will notify about disconnection.
562 virtual bool WillNotifyDisconnection() const = 0; 562 virtual bool WillNotifyDisconnection() const = 0;
563 563
564 // Override the encoding and reload the page by sending down 564 // Override the encoding and reload the page by sending down
565 // ViewMsg_SetPageEncoding to the renderer. |UpdateEncoding| is kinda 565 // ViewMsg_SetPageEncoding to the renderer. |UpdateEncoding| is kinda
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after
744 744
745 private: 745 private:
746 // This interface should only be implemented inside content. 746 // This interface should only be implemented inside content.
747 friend class WebContentsImpl; 747 friend class WebContentsImpl;
748 WebContents() {} 748 WebContents() {}
749 }; 749 };
750 750
751 } // namespace content 751 } // namespace content
752 752
753 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_H_ 753 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698