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

Side by Side Diff: android_webview/native/aw_web_contents_delegate.cc

Issue 2735633004: HTML Media Capture: update capture attribute to use string. (Closed)
Patch Set: Fix for android webview Created 3 years, 8 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 #include "android_webview/native/aw_web_contents_delegate.h" 5 #include "android_webview/native/aw_web_contents_delegate.h"
6 6
7 #include "android_webview/browser/aw_javascript_dialog_manager.h" 7 #include "android_webview/browser/aw_javascript_dialog_manager.h"
8 #include "android_webview/browser/find_helper.h" 8 #include "android_webview/browser/find_helper.h"
9 #include "android_webview/native/aw_contents.h" 9 #include "android_webview/native/aw_contents.h"
10 #include "android_webview/native/aw_contents_io_thread_client_impl.h" 10 #include "android_webview/native/aw_contents_io_thread_client_impl.h"
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
118 Java_AwWebContentsDelegate_runFileChooser( 118 Java_AwWebContentsDelegate_runFileChooser(
119 env, java_delegate, render_frame_host->GetProcess()->GetID(), 119 env, java_delegate, render_frame_host->GetProcess()->GetID(),
120 render_frame_host->GetRoutingID(), mode_flags, 120 render_frame_host->GetRoutingID(), mode_flags,
121 ConvertUTF16ToJavaString( 121 ConvertUTF16ToJavaString(
122 env, base::JoinString(params.accept_types, base::ASCIIToUTF16(","))), 122 env, base::JoinString(params.accept_types, base::ASCIIToUTF16(","))),
123 params.title.empty() ? nullptr 123 params.title.empty() ? nullptr
124 : ConvertUTF16ToJavaString(env, params.title), 124 : ConvertUTF16ToJavaString(env, params.title),
125 params.default_file_name.empty() 125 params.default_file_name.empty()
126 ? nullptr 126 ? nullptr
127 : ConvertUTF8ToJavaString(env, params.default_file_name.value()), 127 : ConvertUTF8ToJavaString(env, params.default_file_name.value()),
128 params.capture); 128 ConvertUTF16ToJavaString(env, params.capture));
129 } 129 }
130 130
131 void AwWebContentsDelegate::AddNewContents(WebContents* source, 131 void AwWebContentsDelegate::AddNewContents(WebContents* source,
132 WebContents* new_contents, 132 WebContents* new_contents,
133 WindowOpenDisposition disposition, 133 WindowOpenDisposition disposition,
134 const gfx::Rect& initial_rect, 134 const gfx::Rect& initial_rect,
135 bool user_gesture, 135 bool user_gesture,
136 bool* was_blocked) { 136 bool* was_blocked) {
137 JNIEnv* env = AttachCurrentThread(); 137 JNIEnv* env = AttachCurrentThread();
138 138
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
313 DVLOG(0) << "File Chooser result: mode = " << mode 313 DVLOG(0) << "File Chooser result: mode = " << mode
314 << ", file paths = " << base::JoinString(file_path_str, ":"); 314 << ", file paths = " << base::JoinString(file_path_str, ":");
315 rfh->FilesSelectedInChooser(files, mode); 315 rfh->FilesSelectedInChooser(files, mode);
316 } 316 }
317 317
318 bool RegisterAwWebContentsDelegate(JNIEnv* env) { 318 bool RegisterAwWebContentsDelegate(JNIEnv* env) {
319 return RegisterNativesImpl(env); 319 return RegisterNativesImpl(env);
320 } 320 }
321 321
322 } // namespace android_webview 322 } // namespace android_webview
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698