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

Side by Side Diff: chrome/browser/android/chrome_web_contents_delegate_android.cc

Issue 1312153003: jni_generator: Pass object parameters as JavaParamRef. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years, 3 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 "chrome/browser/android/chrome_web_contents_delegate_android.h" 5 #include "chrome/browser/android/chrome_web_contents_delegate_android.h"
6 6
7 #include "base/android/jni_android.h" 7 #include "base/android/jni_android.h"
8 #include "base/android/jni_string.h" 8 #include "base/android/jni_string.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "chrome/browser/android/feature_utilities.h" 10 #include "chrome/browser/android/feature_utilities.h"
(...skipping 358 matching lines...) Expand 10 before | Expand all | Expand 10 after
369 if (was_blocked) 369 if (was_blocked)
370 *was_blocked = !handled; 370 *was_blocked = !handled;
371 if (!handled) 371 if (!handled)
372 delete new_contents; 372 delete new_contents;
373 } 373 }
374 374
375 } // namespace android 375 } // namespace android
376 } // namespace chrome 376 } // namespace chrome
377 377
378 jboolean IsCapturingAudio(JNIEnv* env, 378 jboolean IsCapturingAudio(JNIEnv* env,
379 jclass clazz, 379 const JavaParamRef<jclass>& clazz,
380 jobject java_web_contents) { 380 const JavaParamRef<jobject>& java_web_contents) {
381 content::WebContents* web_contents = 381 content::WebContents* web_contents =
382 content::WebContents::FromJavaWebContents(java_web_contents); 382 content::WebContents::FromJavaWebContents(java_web_contents);
383 scoped_refptr<MediaStreamCaptureIndicator> indicator = 383 scoped_refptr<MediaStreamCaptureIndicator> indicator =
384 MediaCaptureDevicesDispatcher::GetInstance()-> 384 MediaCaptureDevicesDispatcher::GetInstance()->
385 GetMediaStreamCaptureIndicator(); 385 GetMediaStreamCaptureIndicator();
386 return indicator->IsCapturingAudio(web_contents); 386 return indicator->IsCapturingAudio(web_contents);
387 } 387 }
388 388
389 jboolean IsCapturingVideo(JNIEnv* env, 389 jboolean IsCapturingVideo(JNIEnv* env,
390 jclass clazz, 390 const JavaParamRef<jclass>& clazz,
391 jobject java_web_contents) { 391 const JavaParamRef<jobject>& java_web_contents) {
392 content::WebContents* web_contents = 392 content::WebContents* web_contents =
393 content::WebContents::FromJavaWebContents(java_web_contents); 393 content::WebContents::FromJavaWebContents(java_web_contents);
394 scoped_refptr<MediaStreamCaptureIndicator> indicator = 394 scoped_refptr<MediaStreamCaptureIndicator> indicator =
395 MediaCaptureDevicesDispatcher::GetInstance()-> 395 MediaCaptureDevicesDispatcher::GetInstance()->
396 GetMediaStreamCaptureIndicator(); 396 GetMediaStreamCaptureIndicator();
397 return indicator->IsCapturingVideo(web_contents); 397 return indicator->IsCapturingVideo(web_contents);
398 } 398 }
OLDNEW
« no previous file with comments | « chrome/browser/android/chrome_application.cc ('k') | chrome/browser/android/compositor/compositor_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698