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

Unified Diff: content/browser/android/web_contents_observer_proxy.cc

Issue 2442303002: Adding new media controls to MediaNotification (Closed)
Patch Set: addressed boliu's comments Created 4 years, 2 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
Index: content/browser/android/web_contents_observer_proxy.cc
diff --git a/content/browser/android/web_contents_observer_proxy.cc b/content/browser/android/web_contents_observer_proxy.cc
index e42d6bd0b5c44cb483da5c5711afdae038a83421..90c04e35222feb2362ab3ddede0212c684545fdc 100644
--- a/content/browser/android/web_contents_observer_proxy.cc
+++ b/content/browser/android/web_contents_observer_proxy.cc
@@ -342,6 +342,22 @@ void WebContentsObserverProxy::MediaSessionMetadataChanged(
j_metadata);
}
+void WebContentsObserverProxy::MediaSessionEnabledAction(
+ blink::mojom::MediaSessionAction action) {
+ JNIEnv* env = AttachCurrentThread();
+ ScopedJavaLocalRef<jobject> obj(java_observer_);
+ Java_WebContentsObserverProxy_mediaSessionEnabledAction(
+ env, obj, static_cast<int>(action));
+}
+
+void WebContentsObserverProxy::MediaSessionDisabledAction(
+ blink::mojom::MediaSessionAction action) {
+ JNIEnv* env = AttachCurrentThread();
+ ScopedJavaLocalRef<jobject> obj(java_observer_);
+ Java_WebContentsObserverProxy_mediaSessionDisabledAction(
+ env, obj, static_cast<int>(action));
+}
+
void WebContentsObserverProxy::SetToBaseURLForDataURLIfNeeded(
std::string* url) {
NavigationEntry* entry =

Powered by Google App Engine
This is Rietveld 408576698