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

Side by Side Diff: chrome/browser/extensions/extension_page_capture_api.cc

Issue 9030032: Get rid of a bunch of tab_contents.h includes from chrome. These are all trivial changes to use W... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: fix cros Created 8 years, 11 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 | Annotate | Revision Log
OLDNEW
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 #include "chrome/browser/extensions/extension_page_capture_api.h" 5 #include "chrome/browser/extensions/extension_page_capture_api.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/file_util.h" 8 #include "base/file_util.h"
9 #include "chrome/browser/browser_process.h" 9 #include "chrome/browser/browser_process.h"
10 #include "chrome/browser/extensions/extension_tab_util.h" 10 #include "chrome/browser/extensions/extension_tab_util.h"
11 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" 11 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h"
12 #include "chrome/common/extensions/extension_messages.h" 12 #include "chrome/common/extensions/extension_messages.h"
13 #include "content/browser/child_process_security_policy.h" 13 #include "content/browser/child_process_security_policy.h"
14 #include "content/browser/renderer_host/render_view_host.h" 14 #include "content/browser/renderer_host/render_view_host.h"
15 #include "content/browser/tab_contents/tab_contents.h"
16 #include "content/browser/download/mhtml_generation_manager.h" 15 #include "content/browser/download/mhtml_generation_manager.h"
17 #include "content/public/browser/notification_details.h" 16 #include "content/public/browser/notification_details.h"
18 #include "content/public/browser/notification_source.h" 17 #include "content/public/browser/notification_source.h"
19 #include "content/public/browser/notification_types.h" 18 #include "content/public/browser/notification_types.h"
19 #include "content/public/browser/render_process_host.h"
20 #include "content/public/browser/web_contents.h"
20 21
21 using content::BrowserThread; 22 using content::BrowserThread;
22 using content::WebContents; 23 using content::WebContents;
23 24
24 // Error messages. 25 // Error messages.
25 const char* const kFileTooBigError = "The MHTML file generated is too big."; 26 const char* const kFileTooBigError = "The MHTML file generated is too big.";
26 const char* const kMHTMLGenerationFailedError = "Failed to generate MHTML."; 27 const char* const kMHTMLGenerationFailedError = "Failed to generate MHTML.";
27 const char* const kSizeRetrievalError = 28 const char* const kSizeRetrievalError =
28 "Failed to retrieve size of generated MHTML."; 29 "Failed to retrieve size of generated MHTML.";
29 const char* const kTemporaryFileError = "Failed to create a temporary file."; 30 const char* const kTemporaryFileError = "Failed to create a temporary file.";
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 WebContents* PageCaptureSaveAsMHTMLFunction::GetWebContents() { 171 WebContents* PageCaptureSaveAsMHTMLFunction::GetWebContents() {
171 Browser* browser = NULL; 172 Browser* browser = NULL;
172 TabContentsWrapper* tab_contents_wrapper = NULL; 173 TabContentsWrapper* tab_contents_wrapper = NULL;
173 174
174 if (!ExtensionTabUtil::GetTabById(tab_id_, profile(), include_incognito(), 175 if (!ExtensionTabUtil::GetTabById(tab_id_, profile(), include_incognito(),
175 &browser, NULL, &tab_contents_wrapper, NULL)) { 176 &browser, NULL, &tab_contents_wrapper, NULL)) {
176 return NULL; 177 return NULL;
177 } 178 }
178 return tab_contents_wrapper->web_contents(); 179 return tab_contents_wrapper->web_contents();
179 } 180 }
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_page_actions_module.cc ('k') | chrome/browser/extensions/extension_processes_api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698