diff options
author | TreeHugger Robot <treehugger-gerrit@google.com> | 2018-10-02 04:23:16 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2018-10-02 04:23:16 +0000 |
commit | e84ba87a6262889b3073921b9dc3b5c9d94fe1c6 (patch) | |
tree | 5817eb35df4dbf8abd2b0bfc8a91d1c88f1f6ea3 /media/lib | |
parent | 3b761c6b3b133c20fd1aa6235dd029435ec2f9cc (diff) | |
parent | 6e038837be37747ddabca2a7d8aaa3a182056b95 (diff) |
Merge "Build com.android.media.remotedisplay with java_sdk_library"
Diffstat (limited to 'media/lib')
11 files changed, 64 insertions, 82 deletions
diff --git a/media/lib/remotedisplay/Android.bp b/media/lib/remotedisplay/Android.bp index 1e9320d1414d..5f4b930f350e 100644 --- a/media/lib/remotedisplay/Android.bp +++ b/media/lib/remotedisplay/Android.bp @@ -14,22 +14,8 @@ // limitations under the License. // -droiddoc { - name: "com.android.media.remotedisplay.stubs-gen-docs", - srcs: [ - "java/**/*.java", - ], - args: " -hide 111 -hide 113 -hide 125 -hide 126 -hide 127 -hide 128 " + - " -stubpackages com.android.media.remotedisplay " + - " -nodocs ", - custom_template: "droiddoc-templates-sdk", - installable: false, -} - -java_library_static { - name: "com.android.media.remotedisplay.stubs", - srcs: [ - ":com.android.media.remotedisplay.stubs-gen-docs", - ], - sdk_version: "current", +java_sdk_library { + name: "com.android.media.remotedisplay", + srcs: ["java/**/*.java"], + api_packages: ["com.android.media.remotedisplay"], } diff --git a/media/lib/remotedisplay/Android.mk b/media/lib/remotedisplay/Android.mk deleted file mode 100644 index e88c0f1a8dc8..000000000000 --- a/media/lib/remotedisplay/Android.mk +++ /dev/null @@ -1,44 +0,0 @@ -# -# Copyright (C) 2013 The Android Open Source Project -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -LOCAL_PATH := $(call my-dir) - -# the remotedisplay library -# ============================================================ -include $(CLEAR_VARS) - -LOCAL_MODULE:= com.android.media.remotedisplay -LOCAL_MODULE_TAGS := optional - -LOCAL_SRC_FILES := $(call all-java-files-under, java) - -include $(BUILD_JAVA_LIBRARY) - - -# ==== com.android.media.remotedisplay.xml lib def ======================== -include $(CLEAR_VARS) - -LOCAL_MODULE := com.android.media.remotedisplay.xml -LOCAL_MODULE_TAGS := optional - -LOCAL_MODULE_CLASS := ETC - -# This will install the file in /system/etc/permissions -# -LOCAL_MODULE_PATH := $(TARGET_OUT_ETC)/permissions - -LOCAL_SRC_FILES := $(LOCAL_MODULE) - -include $(BUILD_PREBUILT) diff --git a/media/lib/remotedisplay/api/current.txt b/media/lib/remotedisplay/api/current.txt new file mode 100644 index 000000000000..e69de29bb2d1 --- /dev/null +++ b/media/lib/remotedisplay/api/current.txt diff --git a/media/lib/remotedisplay/api/removed.txt b/media/lib/remotedisplay/api/removed.txt new file mode 100644 index 000000000000..e69de29bb2d1 --- /dev/null +++ b/media/lib/remotedisplay/api/removed.txt diff --git a/media/lib/remotedisplay/api/system-current.txt b/media/lib/remotedisplay/api/system-current.txt new file mode 100644 index 000000000000..69bbd35fce59 --- /dev/null +++ b/media/lib/remotedisplay/api/system-current.txt @@ -0,0 +1,52 @@ +package com.android.media.remotedisplay { + + public class RemoteDisplay { + ctor public RemoteDisplay(java.lang.String, java.lang.String); + method public java.lang.String getDescription(); + method public java.lang.String getId(); + method public java.lang.String getName(); + method public int getPresentationDisplayId(); + method public int getStatus(); + method public int getVolume(); + method public int getVolumeHandling(); + method public int getVolumeMax(); + method public void setDescription(java.lang.String); + method public void setName(java.lang.String); + method public void setPresentationDisplayId(int); + method public void setStatus(int); + method public void setVolume(int); + method public void setVolumeHandling(int); + method public void setVolumeMax(int); + field public static final int PLAYBACK_VOLUME_FIXED = 0; // 0x0 + field public static final int PLAYBACK_VOLUME_VARIABLE = 1; // 0x1 + field public static final int STATUS_AVAILABLE = 2; // 0x2 + field public static final int STATUS_CONNECTED = 4; // 0x4 + field public static final int STATUS_CONNECTING = 3; // 0x3 + field public static final int STATUS_IN_USE = 1; // 0x1 + field public static final int STATUS_NOT_AVAILABLE = 0; // 0x0 + } + + public abstract class RemoteDisplayProvider { + ctor public RemoteDisplayProvider(android.content.Context); + method public void addDisplay(com.android.media.remotedisplay.RemoteDisplay); + method public com.android.media.remotedisplay.RemoteDisplay findRemoteDisplay(java.lang.String); + method public android.os.IBinder getBinder(); + method public final android.content.Context getContext(); + method public int getDiscoveryMode(); + method public java.util.Collection<com.android.media.remotedisplay.RemoteDisplay> getDisplays(); + method public android.app.PendingIntent getSettingsPendingIntent(); + method public void onAdjustVolume(com.android.media.remotedisplay.RemoteDisplay, int); + method public void onConnect(com.android.media.remotedisplay.RemoteDisplay); + method public void onDisconnect(com.android.media.remotedisplay.RemoteDisplay); + method public void onDiscoveryModeChanged(int); + method public void onSetVolume(com.android.media.remotedisplay.RemoteDisplay, int); + method public void removeDisplay(com.android.media.remotedisplay.RemoteDisplay); + method public void updateDisplay(com.android.media.remotedisplay.RemoteDisplay); + field public static final int DISCOVERY_MODE_ACTIVE = 2; // 0x2 + field public static final int DISCOVERY_MODE_NONE = 0; // 0x0 + field public static final int DISCOVERY_MODE_PASSIVE = 1; // 0x1 + field public static final java.lang.String SERVICE_INTERFACE = "com.android.media.remotedisplay.RemoteDisplayProvider"; + } + +} + diff --git a/media/lib/remotedisplay/api/system-removed.txt b/media/lib/remotedisplay/api/system-removed.txt new file mode 100644 index 000000000000..e69de29bb2d1 --- /dev/null +++ b/media/lib/remotedisplay/api/system-removed.txt diff --git a/media/lib/remotedisplay/api/test-current.txt b/media/lib/remotedisplay/api/test-current.txt new file mode 100644 index 000000000000..e69de29bb2d1 --- /dev/null +++ b/media/lib/remotedisplay/api/test-current.txt diff --git a/media/lib/remotedisplay/api/test-removed.txt b/media/lib/remotedisplay/api/test-removed.txt new file mode 100644 index 000000000000..e69de29bb2d1 --- /dev/null +++ b/media/lib/remotedisplay/api/test-removed.txt diff --git a/media/lib/remotedisplay/com.android.media.remotedisplay.xml b/media/lib/remotedisplay/com.android.media.remotedisplay.xml deleted file mode 100644 index 77a91d23e1d8..000000000000 --- a/media/lib/remotedisplay/com.android.media.remotedisplay.xml +++ /dev/null @@ -1,20 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- Copyright (C) 2013 The Android Open Source Project - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---> - -<permissions> - <library name="com.android.media.remotedisplay" - file="/system/framework/com.android.media.remotedisplay.jar" /> -</permissions> diff --git a/media/lib/remotedisplay/java/com/android/media/remotedisplay/RemoteDisplay.java b/media/lib/remotedisplay/java/com/android/media/remotedisplay/RemoteDisplay.java index dc9dd79eb2b1..8de414b45a4d 100644 --- a/media/lib/remotedisplay/java/com/android/media/remotedisplay/RemoteDisplay.java +++ b/media/lib/remotedisplay/java/com/android/media/remotedisplay/RemoteDisplay.java @@ -16,6 +16,7 @@ package com.android.media.remotedisplay; +import android.annotation.SystemApi; import android.media.RemoteDisplayState.RemoteDisplayInfo; import android.text.TextUtils; @@ -23,7 +24,10 @@ import java.util.Objects; /** * Represents a remote display that has been discovered. + * + * @hide */ +@SystemApi public class RemoteDisplay { private final RemoteDisplayInfo mMutableInfo; private RemoteDisplayInfo mImmutableInfo; diff --git a/media/lib/remotedisplay/java/com/android/media/remotedisplay/RemoteDisplayProvider.java b/media/lib/remotedisplay/java/com/android/media/remotedisplay/RemoteDisplayProvider.java index 4d3edb896eb5..7017e444d717 100644 --- a/media/lib/remotedisplay/java/com/android/media/remotedisplay/RemoteDisplayProvider.java +++ b/media/lib/remotedisplay/java/com/android/media/remotedisplay/RemoteDisplayProvider.java @@ -16,6 +16,7 @@ package com.android.media.remotedisplay; +import android.annotation.SystemApi; import android.app.PendingIntent; import android.app.Service; import android.content.Context; @@ -88,7 +89,10 @@ import java.util.Collection; * IMPORTANT: This class is effectively a public API for unbundled applications, and * must remain API stable. See README.txt in the root of this package for more information. * </p> + * + * @hide */ +@SystemApi public abstract class RemoteDisplayProvider { private static final int MSG_SET_CALLBACK = 1; private static final int MSG_SET_DISCOVERY_MODE = 2; |