Snap for 7183507 from f5941bf624930286ad040d7ab5cf1fdcbdb94334 to sdk-release
Change-Id: I13518186a7f863b637aa15aedc62512afa82972c
diff --git a/Android.bp b/Android.bp
index b38baa2..1df6316 100644
--- a/Android.bp
+++ b/Android.bp
@@ -20,6 +20,34 @@
// transform the framework jar into the temp_layoutlib jar.
//
+package {
+ default_applicable_licenses: ["frameworks_layoutlib_license"],
+}
+
+// Added automatically by a large-scale-change that took the approach of
+// 'apply every license found to every target'. While this makes sure we respect
+// every license restriction, it may not be entirely correct.
+//
+// e.g. GPL in an MIT project might only apply to the contrib/ directory.
+//
+// Please consider splitting the single license below into multiple licenses,
+// taking care not to lose any license_kind information, and overriding the
+// default license using the 'licenses: [...]' property on targets as needed.
+//
+// For unused files, consider creating a 'fileGroup' with "//visibility:private"
+// to attach the license to, and including a comment whether the files may be
+// used in the current project.
+// See: http://go/android-license-faq
+license {
+ name: "frameworks_layoutlib_license",
+ visibility: [":__subpackages__"],
+ license_kinds: [
+ "SPDX-license-identifier-Apache-2.0",
+ "SPDX-license-identifier-EPL",
+ ],
+ // large-scale-change unable to identify any license_text files
+}
+
java_genrule_host {
name: "temp_layoutlib",
tools: ["layoutlib_create"],
diff --git a/METADATA b/METADATA
new file mode 100644
index 0000000..487c3e3
--- /dev/null
+++ b/METADATA
@@ -0,0 +1,11 @@
+third_party {
+ # would be NOTICE save for EPL in:
+ # create/tests/res/mock_data/mock_android/fake/InnerTest.java
+ # create/tests/res/mock_data/mock_android/util/EmptyArray.java
+ # create/tests/res/mock_data/mock_android/view/View.java
+ # create/tests/res/mock_data/mock_android/view/ViewGroup.java
+ # create/tests/res/mock_data/mock_android/widget/LinearLayout.java
+ # create/tests/res/mock_data/mock_android/widget/TableLayout.java
+ # create/tests/res/mock_data/notjava/lang/JavaClass.java
+ license_type: RECIPROCAL
+}
diff --git a/bridge/Android.bp b/bridge/Android.bp
index fa07cb8..e26f711 100644
--- a/bridge/Android.bp
+++ b/bridge/Android.bp
@@ -14,6 +14,10 @@
// limitations under the License.
//
+package {
+ default_applicable_licenses: ["Android-Apache-2.0"],
+}
+
java_library_host {
name: "layoutlib",
diff --git a/bridge/src/com/android/layoutlib/bridge/android/BridgePowerManager.java b/bridge/src/com/android/layoutlib/bridge/android/BridgePowerManager.java
index 584e8c2..92d7fdb 100644
--- a/bridge/src/com/android/layoutlib/bridge/android/BridgePowerManager.java
+++ b/bridge/src/com/android/layoutlib/bridge/android/BridgePowerManager.java
@@ -237,6 +237,11 @@
}
@Override
+ public boolean isAmbientDisplaySuppressedForTokenByApp(String token, int appUid) {
+ return false;
+ }
+
+ @Override
public boolean isAmbientDisplaySuppressed() {
return false;
}
diff --git a/bridge/tests/Android.bp b/bridge/tests/Android.bp
index 5c51c68..7beb94d 100644
--- a/bridge/tests/Android.bp
+++ b/bridge/tests/Android.bp
@@ -12,6 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
+package {
+ default_applicable_licenses: ["Android-Apache-2.0"],
+}
+
java_test_host {
name: "layoutlib-tests",
diff --git a/common/Android.bp b/common/Android.bp
index a256ae2..b33e756 100644
--- a/common/Android.bp
+++ b/common/Android.bp
@@ -14,6 +14,10 @@
// limitations under the License.
//
+package {
+ default_applicable_licenses: ["Android-Apache-2.0"],
+}
+
java_library_host {
name: "layoutlib-common",
diff --git a/create/Android.bp b/create/Android.bp
index 44179a9..0fc219d 100644
--- a/create/Android.bp
+++ b/create/Android.bp
@@ -14,6 +14,16 @@
// limitations under the License.
//
+package {
+ // See: http://go/android-license-faq
+ // A large-scale-change added 'default_applicable_licenses' to import
+ // all of the 'license_kinds' from "frameworks_layoutlib_license"
+ // to get the below license kinds:
+ // SPDX-license-identifier-Apache-2.0
+ // SPDX-license-identifier-EPL
+ default_applicable_licenses: ["frameworks_layoutlib_license"],
+}
+
java_binary_host {
name: "layoutlib_create",
diff --git a/create/tests/Android.bp b/create/tests/Android.bp
index c765707..31fbe22 100644
--- a/create/tests/Android.bp
+++ b/create/tests/Android.bp
@@ -12,6 +12,16 @@
// See the License for the specific language governing permissions and
// limitations under the License.
+package {
+ // See: http://go/android-license-faq
+ // A large-scale-change added 'default_applicable_licenses' to import
+ // all of the 'license_kinds' from "frameworks_layoutlib_license"
+ // to get the below license kinds:
+ // SPDX-license-identifier-Apache-2.0
+ // SPDX-license-identifier-EPL
+ default_applicable_licenses: ["frameworks_layoutlib_license"],
+}
+
java_test_host {
name: "layoutlib-create-tests",
diff --git a/validator/Android.bp b/validator/Android.bp
index 0eff99b..d26c7ef 100644
--- a/validator/Android.bp
+++ b/validator/Android.bp
@@ -14,6 +14,10 @@
// limitations under the License.
//
+package {
+ default_applicable_licenses: ["Android-Apache-2.0"],
+}
+
java_library_host {
name: "layoutlib-validator",