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

Unified Diff: content/public/android/java/src/org/chromium/content/browser/accessibility/captioning/SystemCaptioningBridge.java

Issue 1132053005: Make KitkatCaptioningBridge a singleton (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove unused singleton Created 5 years, 7 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 | « content/public/android/java/src/org/chromium/content/browser/accessibility/captioning/KitKatCaptioningBridge.java ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/android/java/src/org/chromium/content/browser/accessibility/captioning/SystemCaptioningBridge.java
diff --git a/content/public/android/java/src/org/chromium/content/browser/accessibility/captioning/SystemCaptioningBridge.java b/content/public/android/java/src/org/chromium/content/browser/accessibility/captioning/SystemCaptioningBridge.java
index c640622dc4bad275c032a7a4ff04bcd3e78487b6..92a9765ad46e9ba7360cf6db4e89d08a81989d53 100644
--- a/content/public/android/java/src/org/chromium/content/browser/accessibility/captioning/SystemCaptioningBridge.java
+++ b/content/public/android/java/src/org/chromium/content/browser/accessibility/captioning/SystemCaptioningBridge.java
@@ -9,17 +9,35 @@ package org.chromium.content.browser.accessibility.captioning;
*/
public interface SystemCaptioningBridge {
/**
- * Calls all of the delegate's methods with the system's current captioning settings.
+ * Interface for listening to changed from SystemCaptioningBridge.
*/
- public void syncToDelegate();
+ public interface SystemCaptioningBridgeListener {
+ /**
+ * Called when system captioning settings change.
+ *
+ * @param settings The TextTrackSettings object containing the new settings.
+ */
+ public void onSystemCaptioningChanged(TextTrackSettings settings);
+ }
/**
- * Register this bridge for event changes with the system CaptioningManager.
+ * Sync the system's current captioning settings with the listener.
+ *
+ * @param listener The SystemCaptioningBridgeListener object to receive all settings.
*/
- public void registerBridge();
+ public void syncToListener(SystemCaptioningBridgeListener listener);
/**
- * Unregister this bridge from system CaptionManager. Must be called to avoid leaks.
+ * Add a listener for changes with the system CaptioningManager.
+ *
+ * @param listener The SystemCaptioningBridgeListener object to add.
*/
- public void unregisterBridge();
+ public void addListener(SystemCaptioningBridgeListener listener);
+
+ /**
+ * Remove a listener from system CaptionManager.
+ *
+ * @param listener The SystemCaptioningBridgeListener object to remove.
+ */
+ public void removeListener(SystemCaptioningBridgeListener listener);
}
« no previous file with comments | « content/public/android/java/src/org/chromium/content/browser/accessibility/captioning/KitKatCaptioningBridge.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698