summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
authorJae Seo <jaeseo@google.com>2014-07-18 16:12:38 -0700
committerJae Seo <jaeseo@google.com>2014-07-18 17:13:07 -0700
commitbbcd206a798c8c2845200daf7a2d4cb7b29056f3 (patch)
tree6247b892c04612b7d72878ce6e84f9a5d7627225 /services
parent0debc9aff4c0cbc28e083a948081d91b0f171319 (diff)
downloadframeworks_base-bbcd206a798c8c2845200daf7a2d4cb7b29056f3.zip
frameworks_base-bbcd206a798c8c2845200daf7a2d4cb7b29056f3.tar.gz
frameworks_base-bbcd206a798c8c2845200daf7a2d4cb7b29056f3.tar.bz2
TIF: Add a way to notify whether the current program content is allowed
Now we have a complete set of API to tell the entire cases (allowed and blocked), which makes possible for the application to rely more on actions taken by TV input services transferring the responsibility for parental control. Bug: 13172379 Change-Id: I7b0dcf16b870782c76a428a1dac6ef1a528b7d40
Diffstat (limited to 'services')
-rw-r--r--services/core/java/com/android/server/tv/TvInputManagerService.java17
1 files changed, 17 insertions, 0 deletions
diff --git a/services/core/java/com/android/server/tv/TvInputManagerService.java b/services/core/java/com/android/server/tv/TvInputManagerService.java
index 69c693a..78b6883 100644
--- a/services/core/java/com/android/server/tv/TvInputManagerService.java
+++ b/services/core/java/com/android/server/tv/TvInputManagerService.java
@@ -565,6 +565,23 @@ public final class TvInputManagerService extends SystemService {
}
@Override
+ public void onContentAllowed() {
+ synchronized (mLock) {
+ if (DEBUG) {
+ Slog.d(TAG, "onContentAllowed()");
+ }
+ if (sessionState.mSession == null || sessionState.mClient == null) {
+ return;
+ }
+ try {
+ sessionState.mClient.onContentAllowed(sessionState.mSeq);
+ } catch (RemoteException e) {
+ Slog.e(TAG, "error in onContentAllowed");
+ }
+ }
+ }
+
+ @Override
public void onContentBlocked(String rating) {
synchronized (mLock) {
if (DEBUG) {