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

Unified Diff: android_webview/native/aw_contents.cc

Issue 22920005: Refactor MHTMLGenerator to allow getting sending the data to a file descriptor. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/browser/extensions/api/page_capture/page_capture_api.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: android_webview/native/aw_contents.cc
diff --git a/android_webview/native/aw_contents.cc b/android_webview/native/aw_contents.cc
index e6cf84111a1b4098d9374cb2ab6d15a93cc37173..89a3bf95ad0cae6dec5a5a6a6714d56295f4a0a2 100644
--- a/android_webview/native/aw_contents.cc
+++ b/android_webview/native/aw_contents.cc
@@ -302,9 +302,10 @@ void AwContents::GenerateMHTML(JNIEnv* env, jobject obj,
jstring jpath, jobject callback) {
ScopedJavaGlobalRef<jobject>* j_callback = new ScopedJavaGlobalRef<jobject>();
j_callback->Reset(env, callback);
- web_contents_->GenerateMHTML(
- base::FilePath(ConvertJavaStringToUTF8(env, jpath)),
- base::Bind(&GenerateMHTMLCallback, base::Owned(j_callback)));
+ base::FilePath target_path(ConvertJavaStringToUTF8(env, jpath));
+ web_contents_->SaveMHTML(
+ target_path,
+ base::Bind(&GenerateMHTMLCallback, path, base::Owned(j_callback)));
mkosiba (inactive) 2013/08/28 10:34:37 looks like this should be taget_path instead of pa
qsr 2013/08/28 11:21:33 Yep... Thanks and done.
}
void AwContents::PerformLongClick() {
« no previous file with comments | « no previous file | chrome/browser/extensions/api/page_capture/page_capture_api.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698