Commit Graph

20711 Commits

Author SHA1 Message Date
TreeHugger Robot
99334bf938 Merge "Encourage creating Binder tokens with a descriptor." 2018-07-30 15:31:28 +00:00
Martijn Coenen
d2c86ab546 Encourage creating Binder tokens with a descriptor.
Binder tokens (Binder objects without an attached interface) are used
a lot with Android. These tokens don't have an interface descriptor,
which means that proxies (references) to these tokens are impossible
to identify when looking at a heap dump.

To make that easier, introduce a new constructor for Binder that allows
the caller to specify a descriptor.

Bug: 109888955
Test: builds, boots
Change-Id: I18fd00483abc29edf87f84945323a10fe4f6cd42
2018-07-30 12:15:58 +00:00
Lucas Dupin
8f09a5057e Expose Ambient Wallpaper API
In P we introduced a private concept of AOD wallpapers, in Q
we're making it a public surface.

Bug: 111395593
Test: make
Change-Id: I4c406386f0ee15dc8734a24b040482b6cb807126
2018-07-30 10:42:06 +08:00
Seigo Nonaka
a1b12c82a1 Merge "Introduce Font and its builder class" 2018-07-29 03:16:22 +00:00
Phil Weaver
b5df055d34 Merge "Enhance a11y soft keyboard controller" 2018-07-27 23:43:32 +00:00
Jeff Sharkey
3ea5588f7c Merge "Support for appending "standalone" WHERE chunks." 2018-07-27 23:21:53 +00:00
TreeHugger Robot
afeca1dedf Merge "Add a frame commit callback test API" 2018-07-27 22:42:31 +00:00
TreeHugger Robot
3af4a96df7 Merge "Add attribute to control forced dark mode" 2018-07-27 22:33:27 +00:00
Jeff Sharkey
b4cd7588cd Merge "Bind update() args as Object[] for performance." 2018-07-27 20:16:40 +00:00
Phil Weaver
03a65b04d8 Enhance a11y soft keyboard controller
Allow a11y services to request that the soft keyboard be
shown even when the hard keyboard is attached.

Defer to users who override this behavior, and put things
back the way they were when a service requesting this
behavior stops.

Bug: 31012180
Test: Adding CTS tests in linked CL, ran a11y unit tests,
modified TestBack to use the new flag and verified behavior
with a hard keyboard and verfied that settings behave as
expected when overriding and rebooting.
Change-Id: I530481e102ac376a4506b662862ee1ee74815b40
2018-07-27 12:58:18 -07:00
Jeff Sharkey
b89df9eac8 Support for appending "standalone" WHERE chunks.
The existing appendWhere() methods aren't very friendly for
developers, since they require manual tracking of state to decide if
subsequent standalone chunks should be prefixed with "AND".

While it's tempting to offer direct argument binding on the builder
class, we can't really deliver on that API in a secure way, so instead
add separate bindSelection() method which explicitly burns arguments
into a standalone selection string, which can then be appended to
the builder.

This was the last piece of new functionality being used by
SQLiteStatementBuilder, so we can delete that class and migrate
users back to SQLiteQueryBuilder.

Bug: 111268862
Test: atest frameworks/base/core/tests/coretests/src/android/database/DatabaseUtilsTest.java
Test: atest frameworks/base/core/tests/utiltests/src/com/android/internal/util/ArrayUtilsTest.java
Test: atest cts/tests/tests/provider/src/android/provider/cts/MediaStore*
Test: atest cts/tests/tests/database/src/android/database/sqlite/cts/SQLiteQueryBuilderTest.java
Change-Id: I418f24338c90bae8a9dad473fa76329cea00a8c5
2018-07-27 13:45:51 -06:00
John Reck
9ab32f8740 Add a frame commit callback test API
Bug: 111719753
Test: CtsUiRenderingTestCases
Change-Id: Ie08d49b735f5a42a2f06e9049547a2287ecce575
2018-07-27 09:32:08 -07:00
Seigo Nonaka
a1c21c0a02 Introduce Font and its builder class
This CL is a ground work of the new Typeface construction API and
nobody uses this class except for CTS.
I'll add FontFamily class to be able to bundle these Font clases
and register to the Typeface.

Bug: 72665240
Test: atest FontTest
Test: atest CtsWidgetTestCases:EditTextTest
    CtsWidgetTestCases:TextViewFadingEdgeTest
    FrameworksCoreTests:TextViewFallbackLineSpacingTest
    FrameworksCoreTests:TextViewTest FrameworksCoreTests:TypefaceTest
    CtsGraphicsTestCases:TypefaceTest CtsWidgetTestCases:TextViewTest
    CtsTextTestCases FrameworksCoreTests:android.text
    CtsWidgetTestCases:TextViewPrecomputedTextTest

Change-Id: I68555a8b4bd6dd770ba7baae72d9a3777b2087a5
2018-07-26 16:38:44 -07:00
Winson Chung
6b6a71a591 Merge "Consolidate RecentTaskInfo and RunningTaskInfo into TaskInfo class" 2018-07-26 18:58:02 +00:00
Jeff Sharkey
42122bfecf Bind update() args as Object[] for performance.
It's wasteful to convert them to String when SQLite already knows
how to bind specific data types, including funky types like byte[].

Also promote to public API, since they're generally useful.

Bug: 111085900
Test: atest packages/providers/DownloadProvider/tests/
Test: atest cts/tests/app/src/android/app/cts/DownloadManagerTest.java
Test: atest cts/tests/tests/database/src/android/database/sqlite/cts/SQLiteQueryBuilderTest.java
Change-Id: I5b418bca1204773fd2795156a2f47906ca1e1a6b
2018-07-26 10:49:53 -06:00
Philip P. Moltmann
819a6d6a10 Merge "Always review permissions before <M app is started the first time" 2018-07-24 20:57:59 +00:00
Paul Duffin
e23fe81da9 Merge changes from topic "deprecate-iis-closed" am: bba51fede5 am: 9cb60599e4 am: 0001cb000a
am: 450dce9749

Change-Id: I7b98c3aefe9213c888dd6ae8ced39e9db9490057
2018-07-24 12:42:54 -07:00
Paul Duffin
9cb60599e4 Merge changes from topic "deprecate-iis-closed"
am: bba51fede5

Change-Id: Ib9a9603093cd224fd1abe4b6c87cbaf1141eabc4
2018-07-24 12:14:57 -07:00
Philip P. Moltmann
6c644e620d Always review permissions before <M app is started the first time
This splits the
- review permissions
- individually control permissions
- consent to manage wireleess (wifi + bluetooth)
properties.

Almost all code cares only for the first and it is now always true.
Hence a lot of code can be simplified.

Bug: 110431654
Test: atest PermissionsHostTest
      started pre-M app
Change-Id: I733cd476ccd0bf5eaa59e9a9506db34f57c6baee
2018-07-24 11:45:34 -07:00
Shuo Qian
242bf1177f Merge "Call Redirection Surface in Telecom out going call flow" 2018-07-23 20:57:41 +00:00
Paul Duffin
a9c136b43e Deprecate InflaterInputStream.closed field
As recommended by the Android API Council this field is being
deprecated and will be removed from the API in a future release.

Bug: 111592689
Test: make checkbuild

Change-Id: I9aab7396b8b9faadb764fe9d43e80747b3eec018
2018-07-23 16:04:15 +01:00
Paul Duffin
8a20b7b6c6 Correct ordering of TelephonyManager methods
A previous change (db6a391957) seems to
have added some new methods to the api/current.txt manually as they are
in the wrong order. This change corrects the ordering so that they do
not affect future changes to the api/current.txt file.

Bug: 74613795
Test: make checkbuild
Change-Id: I83f9c2ff3cd9f43add297e1c9411598f3eef094f
2018-07-23 16:03:44 +01:00
Jeff Sharkey
e849fffd96 Merge "Revert SQLiteQueryBuilder for now." 2018-07-19 20:12:20 +00:00
Jeff Sharkey
91be9263e3 Revert SQLiteQueryBuilder for now.
We've encountered subtle bugs in how apps are using this public
API, so revert it back to exactly what shipped in the last
release, and move functionality to new SQLiteStatementBuilder
class, since we already have several customers using it.

Test: atest cts/tests/tests/provider/src/android/provider/cts/MediaStore*
Test: atest cts/tests/tests/database/src/android/database/sqlite/cts/SQLiteQueryBuilderTest.java
Bug: 111486645
Change-Id: Ief059e987f2421e19f6f57a94320c313946a26d7
2018-07-19 09:52:20 -06:00
Winson Chung
abfdcceba2 Consolidate RecentTaskInfo and RunningTaskInfo into TaskInfo class
- Remove overlapping logic for building both recent/running task infos
- Deprecate unused members of recent/running task infos
- Skip creating unnecessary recent task info when creating AppTaskImpl

Bug: 111078814
Test: Build and open Overview (ensure it still works)
Test: atest CtsAppTestCases:ActivityManagerRecentTaskInfoTest
Test: atest CtsAppTestCases:ActivityManagerRunningTaskInfoTest
Change-Id: Iaf1731002196bb89319de141a05ab92a7dcb2928
2018-07-18 18:06:47 +00:00
Fredrik Roubert
fde43a2ccf Merge "API updated for ICU4J 62.1" am: e0ec160120 am: 46c84f53a6
am: edf0baea40

Change-Id: I1b1f33db8f1fd3171edbf871e87501570b4673ad
2018-07-18 09:42:38 -07:00
Fredrik Roubert
46c84f53a6 Merge "API updated for ICU4J 62.1"
am: e0ec160120

Change-Id: I19144ce1a0fd7d0a9781a71ebacec033a8affb19
2018-07-18 09:18:46 -07:00
Fredrik Roubert
9182e410ce API updated for ICU4J 62.1
- ICU 62 upgrades to Unicode 11. Add new APIs for Unicode 11.0

Bug: 109930825
Bug: 109837373
Test: make
Change-Id: I3f23bbe624a10511a613cb07fd35e8272d1461a2
2018-07-18 13:00:03 +00:00
John Reck
06efa7169a Merge "Expose async & counter publicly" 2018-07-17 16:46:56 +00:00
Jeff Sharkey
4237b16cac Merge changes from topic "downloadvuln"
* changes:
  Execute "strict" queries with extra parentheses.
  Add support for appending standalone phrases.
2018-07-17 16:12:14 +00:00
Alan Viverette
323fdf2676 Add attribute to control forced dark mode
Bug: 102591313
Test: n/a just a new attribute not used anywhere yet
Change-Id: I046eb402f180b23627f4bfed6f3605c279c9378d
2018-07-17 11:03:07 -04:00
John Reck
d5a9dc06be Expose async & counter publicly
Also add some go-faster to the JNI

Before:
android.os.TracePerfTest:INSTRUMENTATION_STATUS: enabled_mean=13
INSTRUMENTATION_STATUS: enabled_median=13
INSTRUMENTATION_STATUS: enabled_min=13
INSTRUMENTATION_STATUS: enabled_standardDeviation=0
INSTRUMENTATION_STATUS_CODE: -1
.INSTRUMENTATION_STATUS: beginEndSection_mean=3849
INSTRUMENTATION_STATUS: beginEndSection_median=3850
INSTRUMENTATION_STATUS: beginEndSection_min=3829
INSTRUMENTATION_STATUS: beginEndSection_standardDeviation=14
INSTRUMENTATION_STATUS_CODE: -1
.INSTRUMENTATION_STATUS: counter_mean=1836
INSTRUMENTATION_STATUS: counter_median=1837
INSTRUMENTATION_STATUS: counter_min=1832
INSTRUMENTATION_STATUS: counter_standardDeviation=2
INSTRUMENTATION_STATUS_CODE: -1
.INSTRUMENTATION_STATUS: asyncBeginEnd_mean=4992
INSTRUMENTATION_STATUS: asyncBeginEnd_median=4988
INSTRUMENTATION_STATUS: asyncBeginEnd_min=4964
INSTRUMENTATION_STATUS: asyncBeginEnd_standardDeviation=21
INSTRUMENTATION_STATUS_CODE: -1

After:
android.os.TracePerfTest:INSTRUMENTATION_STATUS: enabled_mean=13
INSTRUMENTATION_STATUS: enabled_median=13
INSTRUMENTATION_STATUS: enabled_min=13
INSTRUMENTATION_STATUS: enabled_standardDeviation=0
INSTRUMENTATION_STATUS_CODE: -1
.INSTRUMENTATION_STATUS: beginEndSection_mean=2974
INSTRUMENTATION_STATUS: beginEndSection_median=2971
INSTRUMENTATION_STATUS: beginEndSection_min=2958
INSTRUMENTATION_STATUS: beginEndSection_standardDeviation=15
INSTRUMENTATION_STATUS_CODE: -1
.INSTRUMENTATION_STATUS: counter_mean=1737
INSTRUMENTATION_STATUS: counter_median=1739
INSTRUMENTATION_STATUS: counter_min=1732
INSTRUMENTATION_STATUS: counter_standardDeviation=3
INSTRUMENTATION_STATUS_CODE: -1
.INSTRUMENTATION_STATUS: asyncBeginEnd_mean=3677
INSTRUMENTATION_STATUS: asyncBeginEnd_median=3679
INSTRUMENTATION_STATUS: asyncBeginEnd_min=3663
INSTRUMENTATION_STATUS: asyncBeginEnd_standardDeviation=11
INSTRUMENTATION_STATUS_CODE: -1

Test: builds, benchmarks, verified tracing still works
Bug: 111503982
Change-Id: I71cb026d034bf9b9f97427d10d5ff9ce3d103561
2018-07-17 14:35:01 +00:00
Hall Liu
fce4acd679 Merge "Revert "Revert "Update SubscriptionInfo o use strings for mccmnc""" 2018-07-16 22:52:10 +00:00
Jeff Sharkey
99cc118423 Add support for appending standalone phrases.
When users are building queries, they often need to append several
standalone SQL clauses, and it's tedious to track their first clause
so they can manually append " AND " to each subsequent clause.

So add new appendWherePhrase() API which appends a standalone phrase
which is AND'ed together with any existing WHERE query.

Also fix bug in update() which would turn null values into the
string literal "null" instead of passing them through as SQL NULL.

Test: atest cts/tests/tests/database/src/android/database/sqlite/cts/SQLiteQueryBuilderTest.java
Bug: 111085900
Change-Id: Ia280dd864895654239503e080eaef925f5620d37
2018-07-16 14:56:03 -06:00
sqian
ea8970cd55 Call Redirection Surface in Telecom out going call flow
- Provide a Call Redirection API Surface
- Provide a key "KEY_CALL_REDIRECTION_SERVICE_COMPONENT_NAME_STRING"
  in the CarrierConfigManager
- Create .aidl interfaces for Call Redirection
(CallRedirectionService.aidl, CallRedirectionAdapter.aidl)

Bug: 64959558
Test: Compile
Change-Id: Ic119fa445e66f1275eabf944c77fdc981bc9a2a7
2018-07-16 20:34:07 +00:00
Jack Yu
e3c660b841 Merge "Added documentation for network registration state" am: 3c1604da8b am: 5e7bbe01c4
am: 1d4b1172fe

Change-Id: I2ccc907907029368eec5f4c7cdcaa25eb4c62b16
2018-07-15 19:55:42 -07:00
Jack Yu
5e7bbe01c4 Merge "Added documentation for network registration state"
am: 3c1604da8b

Change-Id: Icf8f0fff21c1190d3bde21cdbe378d6b75b51506
2018-07-15 17:12:41 -07:00
Jeff Sharkey
162d771709 Merge "Extend SQLiteQueryBuilder for update and delete." 2018-07-14 21:35:29 +00:00
Hall Liu
79b6840516 Revert "Revert "Update SubscriptionInfo o use strings for mccmnc""
This reverts commit 0082b161ca.

Reason for revert: build breaks fixed

Change-Id: I75ea63ceaae6e970ce51a971c9a4635d0ce3f9e4
Merged-In: I45c0bfefb7ffe98e3eab8e68d0e1170881ae9f4c
2018-07-14 00:32:56 +00:00
Jeff Sharkey
6adc98c09c Extend SQLiteQueryBuilder for update and delete.
Developers often accept selection clauses from untrusted code, and
SQLiteQueryBuilder already supports a "strict" mode to help catch
SQL injection attacks.  This change extends the builder to support
update() and delete() calls, so that we can help secure those
selection clauses too.

Extend it to support selection arguments being provided when
appending appendWhere() clauses, meaning developers no longer need
to manually track their local selection arguments along with
remote arguments.

Extend it to support newer ContentProvider.query() variant that
accepts "Bundle queryArgs", and have all query() callers flow
through that common code path.  (This paves the way for a future
CL that will offer to gracefully extract non-WHERE clauses that
callers have tried smashing into their selections.)

Updates ContentValues to internally use more efficient ArrayMap.

Bug: 111268862
Test: atest frameworks/base/core/tests/utiltests/src/com/android/internal/util/ArrayUtilsTest.java
Test: atest cts/tests/tests/database/src/android/database/sqlite/cts/SQLiteQueryBuilderTest.java
Change-Id: I60b6f69045766bb28d2f21a32c120ec8c383b917
2018-07-13 18:11:37 -06:00
Jack Yu
b494f72750 Added documentation for network registration state
Also renamed denial reason to reject cause to match
the 3GPP spec.

Bug: 73659459
Test: Build
Change-Id: Ia67ebf94771c7ff5f5d90f6cdd303cb2716f9186
(cherry picked from commit b4094993f7)
2018-07-13 14:50:02 -07:00
Tyler Gunn
ec8b97e60b Merge "Make Connection#onSilence a public API." am: cbe3737f13 am: 01ab0b90bf
am: 9aca012ab5

Change-Id: Icf3491038487e47983b84255cdc32214595ce470
2018-07-13 13:22:48 -07:00
Tyler Gunn
9aca012ab5 Merge "Make Connection#onSilence a public API." am: cbe3737f13
am: 01ab0b90bf

Change-Id: I8c011d4a495d5240ebec83b07bc0b8f57a3c40ac
2018-07-13 12:45:28 -07:00
Jack Yu
1bee26f4c3 Merge "DO NOT MERGE - Revert "Hide IWLAN system API"" into stage-aosp-master 2018-07-13 19:28:23 +00:00
Tyler Gunn
01ab0b90bf Merge "Make Connection#onSilence a public API."
am: cbe3737f13

Change-Id: I4ab192ca160219770d7384e88c8e0025137b42bd
2018-07-13 12:15:45 -07:00
Jack Yu
ad9d544cb3 DO NOT MERGE - Revert "Hide IWLAN system API"
This reverts commit ea440a765e, reversing
changes made to 0b90c524cb.

Test: Build
Bug: 73659459
Change-Id: I2c52f17090040cea589081c3ed412a14986e3d85
2018-07-13 10:35:30 -07:00
Tyler Gunn
cbe3737f13 Merge "Make Connection#onSilence a public API." 2018-07-13 17:02:36 +00:00
Treehugger Robot
f92ad05fa5 Merge "Revert "Update SubscriptionInfo o use strings for mccmnc"" 2018-07-13 16:34:30 +00:00
Yueming Wang
0082b161ca Revert "Update SubscriptionInfo o use strings for mccmnc"
This reverts commit 0c149bd2d8.

Reason for revert:  reverting this topic as it breaks several branches.

Change-Id: Ia01984242e54b5db5d853135b322ebb1284a4d43
Merged-In: I45c0bfefb7ffe98e3eab8e68d0e1170881ae9f4c
2018-07-13 11:15:50 +00:00
Jack Yu
f2add90de4 DO NOT MERGE - Revert "Hide IWLAN system API"
This reverts commit ea440a765e, reversing
changes made to 0b90c524cb.

Test: Build
Bug: 73659459
Change-Id: Id5a5147c6478cf10661aebe52b445bd16195885e
2018-07-12 19:41:33 -07:00