summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author David Zhao <qingxun@google.com> 2023-03-16 05:41:56 +0000
committer Android (Google) Code Review <android-gerrit@google.com> 2023-03-16 05:41:56 +0000
commit9ce369b8d80be78b7d13dd7b094bcd27eb0ddfbc (patch)
treea518bb8b3dfa1c381fdd14ee6dcea7919dd67259
parent6c34756275e261a18034b29734b2c4850185bac8 (diff)
parent0eea615575ec7c5a28bf70ca3a797fa8cba43e5f (diff)
Merge "Update onTvMessage callback to also be int" into udc-dev
-rw-r--r--core/api/current.txt2
-rw-r--r--media/java/android/media/tv/ITvInputSessionWrapper.java2
-rw-r--r--media/java/android/media/tv/TvInputService.java4
3 files changed, 4 insertions, 4 deletions
diff --git a/core/api/current.txt b/core/api/current.txt
index 02de1cd9a137..b4f2df58db19 100644
--- a/core/api/current.txt
+++ b/core/api/current.txt
@@ -27478,7 +27478,7 @@ package android.media.tv {
method public boolean onTrackballEvent(android.view.MotionEvent);
method public abstract boolean onTune(android.net.Uri);
method public boolean onTune(android.net.Uri, android.os.Bundle);
- method public void onTvMessage(@NonNull String, @NonNull android.os.Bundle);
+ method public void onTvMessage(int, @NonNull android.os.Bundle);
method public void onUnblockContent(android.media.tv.TvContentRating);
method public void setOverlayViewEnabled(boolean);
}
diff --git a/media/java/android/media/tv/ITvInputSessionWrapper.java b/media/java/android/media/tv/ITvInputSessionWrapper.java
index 7946baee200a..f939f523d3fa 100644
--- a/media/java/android/media/tv/ITvInputSessionWrapper.java
+++ b/media/java/android/media/tv/ITvInputSessionWrapper.java
@@ -280,7 +280,7 @@ public class ITvInputSessionWrapper extends ITvInputSession.Stub implements Hand
}
case DO_NOTIFY_TV_MESSAGE: {
SomeArgs args = (SomeArgs) msg.obj;
- mTvInputSessionImpl.onTvMessageReceived((String) args.arg1, (Bundle) args.arg2);
+ mTvInputSessionImpl.onTvMessageReceived((Integer) args.arg1, (Bundle) args.arg2);
break;
}
default: {
diff --git a/media/java/android/media/tv/TvInputService.java b/media/java/android/media/tv/TvInputService.java
index 4e380c41ccdb..0d283fa87c19 100644
--- a/media/java/android/media/tv/TvInputService.java
+++ b/media/java/android/media/tv/TvInputService.java
@@ -1512,7 +1512,7 @@ public abstract class TvInputService extends Service {
* See {@link TvInputManager#TV_MESSAGE_KEY_SUBTYPE} for more information on
* how to parse this data.
*/
- public void onTvMessage(@NonNull @TvInputManager.TvMessageType String type,
+ public void onTvMessage(@TvInputManager.TvMessageType int type,
@NonNull Bundle data) {
}
@@ -2065,7 +2065,7 @@ public abstract class TvInputService extends Service {
onAdBufferReady(buffer);
}
- void onTvMessageReceived(String type, Bundle data) {
+ void onTvMessageReceived(int type, Bundle data) {
onTvMessage(type, data);
}