6423 Commits

Author SHA1 Message Date
Michael Wright
7121697a5e BZZZZZZT! BZZZZZT! New Vibrator APIs
Replace the existing Vibrator APIs with a new class to encapsulate the
haptic effect information, and add the ability to control the vibration
strength.

Test: cts-tradefed run commandAndExit cts-dev -m CtsOsTestCases -t android.os.cts.VibratorTest
      cts-tradefed run commandAndExit cts-dev -m CtsOsTestCases -t android.os.cts.VibrationEffectTest
      runtest systemui-notification
      Manual testing with $T/google_experimental/users/michaelwr/Vibrator

Bug: 30961353

Change-Id: Idbb9864a7b084c85e7b7de3257a0e6b40d9d91d6
2017-03-20 16:09:51 +00:00
Jeff Sharkey
683bcd30ef Use allocatable space when measuring for install.
The system is often willing to clear cached data to make room for
incoming installs, so use StorageManager.getAllocatableBytes() when
making "does it fit?" style decisions.

Add new INSTALL_ALLOCATE_AGGRESSIVE flag, which will flow through
to use StorageManager.FLAG_ALLOCATE_AGGRESSIVE when making allocation
related requests.  (This can be used by installers to indicate
packages that are critical to system health or security.

Test: runtest -x frameworks/base/core/tests/coretests/src/android/content/pm/PackageHelperTests.java
Bug: 36131437
Change-Id: If8118762fd1ca1f497d2cdd1787bdb3c9759dcc0
2017-03-18 17:54:54 -06:00
Felipe Leme
28afe0e1d8 Batch autofill() calls to views with virtual children.
This is useful in the cases where the virtual children hierarchy is rendered
by a different process.

Test: VirtualContainerActivityTest pass
Bug: 36056207
Change-Id: Id9bf3a9e9366b616dc2a6e0a204e238a2bee3a20
2017-03-18 11:25:23 -07:00
Eric Laurent
2eb39497bc Add missing type for USB headset devices
Change-Id: Ib3195442bfefd00edf46592e743617fe37b81a33
Test: audio playback and capture regression tests
2017-03-17 17:25:15 -07:00
Adam Lesinski
10eb1455b9 Merge changes from topic 'configForSplit'
* changes:
  libandroidfw: Search all packages for an identifier
  AAPT2: Finish support for feature splits
  Add support for configForSplit
2017-03-17 23:19:13 +00:00
Jakub Pawlowski
def6fee7f5 Merge "Bluetooth 5 move timeout parameter (1/2)" am: d9f2f67a5f am: 07d79aa3b0
am: acd3953ea1

Change-Id: Ic2c7bd33d558bb4e8cfff063c95f2fa137aeaae0
2017-03-17 23:09:10 +00:00
Jakub Pawlowski
adbf2eef2f Bluetooth 5 move timeout parameter (1/2)
Timeout is not a parameter, it is a property of enabling the
advertising. Move it into more proper place.

Test: manual
Bug: 30622771
Change-Id: I09ebc6c770bc02938ea16a9738a7e03dc8006fde
2017-03-17 22:23:57 +00:00
TreeHugger Robot
ef8297e275 Merge "Send broadcast when user restrictions change." 2017-03-17 20:48:36 +00:00
TreeHugger Robot
741a898514 Merge "Adding an extras Bundle to MessagingStyle messages." 2017-03-17 19:38:02 +00:00
TreeHugger Robot
2fb89f45b9 Merge "Removed 'virtual' from autofill method names." 2017-03-17 17:54:37 +00:00
TreeHugger Robot
6e4075bde6 Merge "Adding enabled state for remote actions." 2017-03-17 17:51:45 +00:00
Felipe Leme
81f01d9efd Removed 'virtual' from autofill method names.
Fixes: 36126001
Test: VirtualContainerActivityTest pass

Change-Id: I3b8fe835cd7c7f39c8e2cb8f2daca71b03236a1f
2017-03-17 09:09:31 -07:00
Julia Reynolds
f619bc5211 Removing 'delegate' from constant names
Change-Id: I2ac4e3ae08f1084da34ea74fdd5177e2d58987af
Fixes: 35812334
Test: build
2017-03-17 08:43:22 -04:00
Jakub Pawlowski
7800604d0d Merge "LE Maximum Advertising Data Length (1/4)" am: 74f2e1a303 am: 2fc3834f4d
am: 066e8551f1

Change-Id: If9ee85705e7c47820e23ad79a048e4c04c4cc11a
2017-03-17 05:31:07 +00:00
Felipe Leme
24aae15218 Added a new AutofillCallback.EVENT_INPUT_UNAVAILABLE event.
This event is called when:

- After notifyViewEntered() when autofill is disabled.
- After service returns an "empty" FillResponse to FillCallback.onSuccess().

BUG: 36056207

Test: LoginActivityTest.testAutofillCallbackDisabled
Test: LoginActivityTest.testAutofillCallbackNoDatasets
Test: VirtualContainerActivityTest.testAutofillCallbackDisabled
Test: VirtualContainerActivityTest.testAutofillCallbackNoDatasets

Change-Id: I7b8636473f738bf600aa96b28c77827b2cc78815
2017-03-16 19:40:22 -07:00
Philip P. Moltmann
389d1c2b43 Merge "TRON log important auto-fill events" 2017-03-17 02:23:35 +00:00
Jakub Pawlowski
ad10affa4e LE Maximum Advertising Data Length (1/4)
Add ability to check maximum advertising data length.

Bug: 30622771
Test: manual
Change-Id: I281f7e9f294c40a47a67a22809cc753b6693f7c4
2017-03-16 18:27:01 -07:00
Winson Chung
6b88baf1e8 Adding enabled state for remote actions.
- Actions can specify whether they are enabled (default) or disabled, and
  SystemUI will reflect the state in the PiP actions.

Bug: 36363677
Test: Expand pip with dismissed action
Change-Id: I36994868f82d8ba0fc87947a722d9f20b39425a1
2017-03-16 18:05:30 -07:00
Chris Craik
97b4ccbd97 Merge "Expose color filter mutate methods" 2017-03-17 00:32:21 +00:00
Makoto Onuki
e72f81b64d Send broadcast when user restrictions change.
- Send UserManager.ACTION_USER_RESTRICTIONS_CHANGED, which is a runtime receiver
only broadcast.

Bug 36355208

Test: cts-tradefed run cts-dev --skip-device-info --skip-preconditions --skip-system-status-check com.android.compatibility.common.tradefed.targetprep.NetworkConnectivityChecker -a armeabi-v7a -l INFO -m CtsDevicePolicyManagerTestCases -t 'com.android.cts.devicepolicy.UserRestrictionsTest#testUserRestrictions_deviceOwnerOnly'
Test: cts-tradefed run cts-dev --skip-device-info --skip-preconditions --skip-system-status-check com.android.compatibility.common.tradefed.targetprep.NetworkConnectivityChecker -a armeabi-v7a -l INFO -m CtsDevicePolicyManagerTestCases -t 'com.android.cts.devicepolicy.UserRestrictionsTest#testUserRestrictions_primaryProfileOwnerOnly'
Test: cts-tradefed run cts-dev --skip-device-info --skip-preconditions --skip-system-status-check com.android.compatibility.common.tradefed.targetprep.NetworkConnectivityChecker -a armeabi-v7a -l INFO -m CtsDevicePolicyManagerTestCases -t 'com.android.cts.devicepolicy.UserRestrictionsTest#testUserRestrictions_secondaryProfileOwnerOnly'
Change-Id: Ifd82e39ce2c08ed5accdf017f4a1ea3af6face63
2017-03-16 15:51:11 -07:00
Chris Craik
6097eca721 Expose color filter mutate methods
Bug: 36025103
Test: cts-tradefed run singleCommand cts-dev --module CtsGraphicsTestCases

Now, similar to Shaders, we defer native creation until Paint is being
used, and ensure that we have an up to date filter when drawing.

Also implements ColorMatrix#equals to behave like Matrix#equals.

Change-Id: I5f74addd97f5662800802e6f660fead58d518725
2017-03-16 15:45:43 -07:00
Adam Lesinski
1665d0f028 Add support for configForSplit
Applications with the android:isolatedSplits="true" attribute in
their AndroidManifest.xml would have their Split APKs loaded in
isolation of each other, based on a set of dependencies.

Configuration Splits generated for a Feature split would not be properly
loaded before, so this change, along with a tools change, fixes this
issue and completes support for isolatedSplits.

Bug: 30999713
Test: CTS test coming (depends on some tool changes)
Change-Id: Ia4e7b0e69168a9d6637867558e306f7031720fb3
2017-03-16 15:45:10 -07:00
Philip P. Moltmann
7b77116802 TRON log important auto-fill events
Example log from
android.autofillservice.cts.LoginActivityTest#testAutoFill#testAutoFillOneDatasetAndSave
(translated from numbers of human readable string):

AUTOFILL_SESSION_STARTED
   package=android.autofillservice.cts
AUTOFILL_REQUEST
   type=TYPE_SUCCESS
   package=android.autofillservice.cts
   FIELD_AUTOFILL_SERVICE=android.autofillservice.cts
   FIELD_AUTOFILL_NUM_DATASETS=1
AUTOFILL_FILL_UI
   type=TYPE_ACTION
   package=android.autofillservice.cts
   FIELD_AUTOFILL_NUM_DATASETS=1
   FIELD_AUTOFILL_FILTERTEXT_LEN=0
AUTOFILL_DATASET_APPLIED
   package=android.autofillservice.cts
   FIELD_AUTOFILL_NUM_VALUES=2
   FIELD_AUTOFILL_NUM_VIEWS_FILLED=2
AUTOFILL_SAVE_UI
   package=android.autofillservice.cts
   FIELD_AUTOFILL_NUM_IDS=2
AUTOFILL_DATA_SAVE_REQUEST
   type=TYPE_SUCCESS
   package=android.autofillservice.cts
   FIELD_AUTOFILL_SERVICE=android.autofillservice.cts
AUTOFILL_SESSION_FINISHED
   package=android.autofillservice.cts

Test: Ran auto-fill tests and looked at event log.
Change-Id: I58aaa58e4435e7d04c8cd91878411943d3eb13de
2017-03-16 15:41:33 -07:00
TreeHugger Robot
2bd3c49eb4 Merge "Add feature tag android.hardware.vr.headtracking." 2017-03-16 20:28:03 +00:00
Craig Donner
279dd66dfd Add feature tag android.hardware.vr.headtracking.
Different versions of this feature specify different levels of
headtracking capability.

Bug: 36294374
Test: build
Change-Id: I00273c9093321661b5ca519d7cd065ae0105c3b2
2017-03-16 11:48:27 -07:00
Julia Reynolds
9bfba59417 Better deletions
- Allow apps to delete notification groups (which cascade to delete all
channels therein)
- Allow apps to get their groups, so they know what they might want to
delete
- Don't throw if someone tries to delete something that already doesn't
exist.

Change-Id: I5f6e25497c5da1e57b52737586e86097332f88f9
Fixes: 36245468
Fixes: 36127382
Test: runtest systemui-notification, cts
2017-03-16 14:32:50 +00:00
Julia Reynolds
1d97e6a0c1 Remove resource id channel/group name fields
Apps can listen for the LOCALE_CHANGED broadcast to
change names if needed.

Fixes: 35336590
Test: runtest systemui-notification, cts, manual
Change-Id: I62d2778f61e99200692755a6f268828a374837e6
2017-03-16 14:20:28 +00:00
TreeHugger Robot
5bf03b7640 Merge "Allow users to manually request Autofill." 2017-03-16 01:33:46 +00:00
Ray Essick
5204ad0a2a Merge "Integrate API Council feedback into Media Metrics APIs" 2017-03-16 01:02:25 +00:00
Conrad Chen
287a68e62a Merge "Deprecate settingsActivity field in TvInputService" 2017-03-16 00:16:15 +00:00
Okan Kolak
bfd10ebcb4 Merge "Voice Messaging Intent API." 2017-03-15 23:34:32 +00:00
Jeff Davidson
6f599559dd Merge "Rename getDataEnabled() to isDataEnabled()." 2017-03-15 22:43:23 +00:00
Seigo Nonaka
0763650a13 Notify caller if none of settings are effective.
Now setFontVariationSettings returns false if the given settings is not
effective.

Bug:35764323
Test: ran TextViewTest and PaintTest in cts
Change-Id: Ic31d9e47ec006c8e7bb2c907ff0ea2936bd71d01
2017-03-15 14:05:37 -07:00
Shane Brennan
5a871867f5 Adding an extras Bundle to MessagingStyle messages.
This allows extending each message with standard extenders.

Test: Will be adding CTS test in a separate CL.

Change-Id: I2ce35cc28e0f374af02e0ad1228f473a63ff7740
2017-03-15 13:16:16 -07:00
TreeHugger Robot
5fff20cac1 Merge "Clean up public FontConfig APIs" 2017-03-15 18:52:04 +00:00
Ray Essick
f2d0e40bf0 Integrate API Council feedback into Media Metrics APIs
Integrates the API Council's feedback into the Media Metrics
related APIs.
-- return types for the getMetrics() calls
-- definition of keys in the set of data that comes back

Bug: 35811992
Test: booted, CTS subset, checked dumpsys media.metrics output
Change-Id: Ib750f9631bd3453be3132760273ccfff0a891f88
2017-03-15 11:43:08 -07:00
Shubang Lu
3ff3dde601 Merge "TIF: add cable detection for TV inputs" 2017-03-15 17:29:11 +00:00
Seigo Nonaka
ac873c9f25 Clean up public FontConfig APIs
This CL contains following clean up:

- Hide unnecessary constructors.
- Change List<XX> to XX[] since actually all fields are immutable.
- Change font's variant type from String to int.
- Decouple resource related members to FontResourcesParser.
- Add NonNull/Nullable to all fields.

Test: ran android.content.res.FontResourcesParserTest

Change-Id: If456266ffff86d41342572a19662cc8f3cd13181
2017-03-15 10:16:55 -07:00
TreeHugger Robot
be4cf58436 Merge "Add API to mark apps that have an update available" 2017-03-15 17:04:22 +00:00
Felipe Leme
2ac463e3f5 Allow users to manually request Autofill.
- Added a requestAutofill(view,flags) method, that when passed with
  FLAG_MANUAL_AUTOFILL triggers a manual request.
- Added same method for virtual views
- Overloaded existing AutofillService request methods to take a flag.
- Added an AUTOFILL context menu option on TextViews.
- Added a canRequestAutofill() that is used to enable the context menu.

BUG: 35708229
Test: manual verification
Test: existing CtsAutoFillServiceTestCases pass
Test: android.autofillservice.cts.LoginActivityTest#testManualAutofill pass

Change-Id: I1a64d40da3373774451d178b1cabf20f11120e9d
2017-03-15 09:37:10 -07:00
Todd Kennedy
ab53289c59 Add API to mark apps that have an update available
Ostensibly for instant apps, we allow play to mark an app as having
an update available. This will trigger instant app resolution even
if the instant app is already installed on device.

Bug: 35143464
Test: Manual; launch URI of installed instant app, see it runs w/o resolution. set bit. launch URI of installed instant app, see it runs resolution
Change-Id: I511df2b2a3eab39377167c770255ccbe02d5dad2
2017-03-15 07:31:09 -07:00
TreeHugger Robot
a98767ab7f Merge "Apply static RRO" 2017-03-15 04:30:33 +00:00
Eugene Susla
7c3eef2f3d Add system feature for Companion Device Manager
Bug: 30932767
Test: Add just the feature gating first, ensure Context#getSystemSetrvice now
returns null.
Add feature in the configuration files, ensure companion device feature works again.
Change-Id: I4ad2d52f7877eae0e951f43ddbb23881d5de8d8b
2017-03-14 19:50:49 -07:00
Conrad Chen
3f547dcce2 Deprecate settingsActivity field in TvInputService
Test: build
Bug: 27325064
Change-Id: Ieb38cc06f49b3944387ba4bbb11b953e35f06d89
2017-03-14 18:08:47 -07:00
Felipe Leme
82e3793c15 Decouple Dataset ids from SaveInfo.
The FillResponse was automatically adding the AutofillId of all Datasets to
the SaveInfo object, but that would cause problems when the AutofillService
is not able to save some data (for example, if it comes from a read-only
backend).

Bug: 36076444
Test: OptionalSaveActivityTest pass
Test: m update-api
Change-Id: I1d5faaddf29e1be0f357438c8485e07caf975293
2017-03-14 15:56:58 -07:00
Ammar Aijazi
552d83674d Merge "Add carrier config keys to control the data cycle." 2017-03-14 22:20:16 +00:00
Philip P. Moltmann
9b31b4eac8 Merge "Make it clear which type of AutoFillValue is set" 2017-03-14 21:59:39 +00:00
Philip P. Moltmann
37bf8b1736 Merge "Change autoFillHint to list of strings" 2017-03-14 21:13:14 +00:00
TreeHugger Robot
123a34f193 Merge "Renamed ViewStructure.setSanitized() to setDataIsSensitive()." 2017-03-14 19:27:20 +00:00
Felipe Leme
c9a19b1b27 Renamed ViewStructure.setSanitized() to setDataIsSensitive().
Bug: 36126001
Test: CtsAutoFillServiceTestCases pass
Test: m update-api

Change-Id: I182355b63d8743cd8cd8612f29a9269e258283c2
2017-03-14 17:51:47 +00:00