Loading media/java/android/media/tv/ITvInputClient.aidl +1 −0 Original line number Diff line number Diff line Loading @@ -44,6 +44,7 @@ oneway interface ITvInputClient { void onTrackSelected(int type, in String trackId, int seq); void onVideoAvailable(int seq); void onVideoUnavailable(int reason, int seq); void onVideoFreezeUpdated(boolean isFrozen, int seq); void onContentAllowed(int seq); void onContentBlocked(in String rating, int seq); void onLayoutSurface(int left, int top, int right, int bottom, int seq); Loading media/java/android/media/tv/ITvInputSessionCallback.aidl +1 −0 Original line number Diff line number Diff line Loading @@ -41,6 +41,7 @@ oneway interface ITvInputSessionCallback { void onTrackSelected(int type, in String trackId); void onVideoAvailable(); void onVideoUnavailable(int reason); void onVideoFreezeUpdated(boolean isFrozen); void onContentAllowed(); void onContentBlocked(in String rating); void onLayoutSurface(int left, int top, int right, int bottom); Loading media/java/android/media/tv/TvInputManager.java +34 −0 Original line number Diff line number Diff line Loading @@ -739,6 +739,15 @@ public final class TvInputManager { public void onVideoUnavailable(Session session, int reason) { } /** * This is called when the video freeze state has been updated. * If {@code true}, the video is frozen on the last frame while audio playback continues. * @param session A {@link TvInputManager.Session} associated with this callback. * @param isFrozen Whether the video is frozen */ public void onVideoFreezeUpdated(Session session, boolean isFrozen) { } /** * This is called when the current program content turns out to be allowed to watch since * its content rating is not blocked by parental controls. Loading Loading @@ -1030,6 +1039,19 @@ public final class TvInputManager { }); } void postVideoFreezeUpdated(boolean isFrozen) { mHandler.post(new Runnable() { @Override public void run() { mSessionCallback.onVideoFreezeUpdated(mSession, isFrozen); if (mSession.mIAppNotificationEnabled && mSession.getInteractiveAppSession() != null) { mSession.getInteractiveAppSession().notifyVideoFreezeUpdated(isFrozen); } } }); } void postContentAllowed() { mHandler.post(new Runnable() { @Override Loading Loading @@ -1545,6 +1567,18 @@ public final class TvInputManager { } } @Override public void onVideoFreezeUpdated(boolean isFrozen, int seq) { synchronized (mSessionCallbackRecordMap) { SessionCallbackRecord record = mSessionCallbackRecordMap.get(seq); if (record == null) { Log.e(TAG, "Callback not found for seq " + seq); return; } record.postVideoFreezeUpdated(isFrozen); } } @Override public void onContentAllowed(int seq) { synchronized (mSessionCallbackRecordMap) { Loading media/java/android/media/tv/TvInputService.java +28 −0 Original line number Diff line number Diff line Loading @@ -762,6 +762,34 @@ public abstract class TvInputService extends Service { }); } /** * Informs the application that the video freeze state has been updated. * * When {@code true}, the video is frozen on the last frame but audio playback remains * active. * * @param isFrozen Whether or not the video is frozen * @hide */ public void notifyVideoFreezeUpdated(boolean isFrozen) { executeOrPostRunnableOnMainThread(new Runnable() { @MainThread @Override public void run() { try { if (DEBUG) { Log.d(TAG, "notifyVideoFreezeUpdated"); } if (mSessionCallback != null) { mSessionCallback.onVideoFreezeUpdated(isFrozen); } } catch (RemoteException e) { Log.e(TAG, "error in notifyVideoFreezeUpdated", e); } } }); } /** * Sends an updated list of all audio presentations available from a Next Generation Audio * service. This is used by the framework to maintain the audio presentation information for Loading media/java/android/media/tv/interactive/ITvInteractiveAppManager.aidl +1 −0 Original line number Diff line number Diff line Loading @@ -88,6 +88,7 @@ interface ITvInteractiveAppManager { void notifyTracksChanged(in IBinder sessionToken, in List<TvTrackInfo> tracks, int userId); void notifyVideoAvailable(in IBinder sessionToken, int userId); void notifyVideoUnavailable(in IBinder sessionToken, int reason, int userId); void notifyVideoFreezeUpdated(in IBinder sessionToken, boolean isFrozen, int userId); void notifyContentAllowed(in IBinder sessionToken, int userId); void notifyContentBlocked(in IBinder sessionToken, in String rating, int userId); void notifySignalStrength(in IBinder sessionToken, int stength, int userId); Loading Loading
media/java/android/media/tv/ITvInputClient.aidl +1 −0 Original line number Diff line number Diff line Loading @@ -44,6 +44,7 @@ oneway interface ITvInputClient { void onTrackSelected(int type, in String trackId, int seq); void onVideoAvailable(int seq); void onVideoUnavailable(int reason, int seq); void onVideoFreezeUpdated(boolean isFrozen, int seq); void onContentAllowed(int seq); void onContentBlocked(in String rating, int seq); void onLayoutSurface(int left, int top, int right, int bottom, int seq); Loading
media/java/android/media/tv/ITvInputSessionCallback.aidl +1 −0 Original line number Diff line number Diff line Loading @@ -41,6 +41,7 @@ oneway interface ITvInputSessionCallback { void onTrackSelected(int type, in String trackId); void onVideoAvailable(); void onVideoUnavailable(int reason); void onVideoFreezeUpdated(boolean isFrozen); void onContentAllowed(); void onContentBlocked(in String rating); void onLayoutSurface(int left, int top, int right, int bottom); Loading
media/java/android/media/tv/TvInputManager.java +34 −0 Original line number Diff line number Diff line Loading @@ -739,6 +739,15 @@ public final class TvInputManager { public void onVideoUnavailable(Session session, int reason) { } /** * This is called when the video freeze state has been updated. * If {@code true}, the video is frozen on the last frame while audio playback continues. * @param session A {@link TvInputManager.Session} associated with this callback. * @param isFrozen Whether the video is frozen */ public void onVideoFreezeUpdated(Session session, boolean isFrozen) { } /** * This is called when the current program content turns out to be allowed to watch since * its content rating is not blocked by parental controls. Loading Loading @@ -1030,6 +1039,19 @@ public final class TvInputManager { }); } void postVideoFreezeUpdated(boolean isFrozen) { mHandler.post(new Runnable() { @Override public void run() { mSessionCallback.onVideoFreezeUpdated(mSession, isFrozen); if (mSession.mIAppNotificationEnabled && mSession.getInteractiveAppSession() != null) { mSession.getInteractiveAppSession().notifyVideoFreezeUpdated(isFrozen); } } }); } void postContentAllowed() { mHandler.post(new Runnable() { @Override Loading Loading @@ -1545,6 +1567,18 @@ public final class TvInputManager { } } @Override public void onVideoFreezeUpdated(boolean isFrozen, int seq) { synchronized (mSessionCallbackRecordMap) { SessionCallbackRecord record = mSessionCallbackRecordMap.get(seq); if (record == null) { Log.e(TAG, "Callback not found for seq " + seq); return; } record.postVideoFreezeUpdated(isFrozen); } } @Override public void onContentAllowed(int seq) { synchronized (mSessionCallbackRecordMap) { Loading
media/java/android/media/tv/TvInputService.java +28 −0 Original line number Diff line number Diff line Loading @@ -762,6 +762,34 @@ public abstract class TvInputService extends Service { }); } /** * Informs the application that the video freeze state has been updated. * * When {@code true}, the video is frozen on the last frame but audio playback remains * active. * * @param isFrozen Whether or not the video is frozen * @hide */ public void notifyVideoFreezeUpdated(boolean isFrozen) { executeOrPostRunnableOnMainThread(new Runnable() { @MainThread @Override public void run() { try { if (DEBUG) { Log.d(TAG, "notifyVideoFreezeUpdated"); } if (mSessionCallback != null) { mSessionCallback.onVideoFreezeUpdated(isFrozen); } } catch (RemoteException e) { Log.e(TAG, "error in notifyVideoFreezeUpdated", e); } } }); } /** * Sends an updated list of all audio presentations available from a Next Generation Audio * service. This is used by the framework to maintain the audio presentation information for Loading
media/java/android/media/tv/interactive/ITvInteractiveAppManager.aidl +1 −0 Original line number Diff line number Diff line Loading @@ -88,6 +88,7 @@ interface ITvInteractiveAppManager { void notifyTracksChanged(in IBinder sessionToken, in List<TvTrackInfo> tracks, int userId); void notifyVideoAvailable(in IBinder sessionToken, int userId); void notifyVideoUnavailable(in IBinder sessionToken, int reason, int userId); void notifyVideoFreezeUpdated(in IBinder sessionToken, boolean isFrozen, int userId); void notifyContentAllowed(in IBinder sessionToken, int userId); void notifyContentBlocked(in IBinder sessionToken, in String rating, int userId); void notifySignalStrength(in IBinder sessionToken, int stength, int userId); Loading