166 Commits

Author SHA1 Message Date
Jeff Sharkey
a4d34d971c Respond to API council feedback.
Move aggressive allocation to @SystemApi, which means we can hide
the "flags" API variants.

Remove UUID APIs, since we should use existing Serializable APIs.

Relax permission checks to allow apps to ask for their own stats.

Improve docs.

Test: cts-tradefed run commandAndExit cts-dev -m CtsAppSecurityHostTestCases -t android.appsecurity.cts.StorageHostTest
Bug: 37534687, 37534941, 37718184, 37738770
Change-Id: I6a763fb3ab3169c8d3329765bb31e1ee08d9ced7
2017-04-27 11:33:39 -06:00
TreeHugger Robot
424dd39e25 Merge "setAffiliationIds and getAffiliationIds uses set instead of list" into oc-dev 2017-04-27 09:41:18 +00:00
Tony Mak
3165743c50 setAffiliationIds and getAffiliationIds uses set instead of list
Didn't use @remove because java doesn't support two methods differs from
the return type only.

Test: cts-tradefed run cts-dev --module DevicePolicyManager --test com.android.cts.devicepolicy.DeviceOwnerTest#testLockTask_unaffiliatedUser
Test: runtest -x frameworks/base/services/tests/servicestests/src/com/android/server/devicepolicy/DevicePolicyManagerTest.java
Test: cts-tradefed run cts-dev --module DevicePolicyManager  --test com.android.cts.devicepolicy.DeviceOwnerPlusProfileOwnerTest

Change-Id: Ic7c7221ef5e680a6765f028c2ab73d4c2f908c58
Fix: 37622682
2017-04-26 22:42:19 +00:00
Seigo Nonaka
54084b64b1 Font provider cleaning ups.
- Remove Columns.STYLE
- Decouple Context from Typeface.
- Make FontsContract constructor private since it is essentially static.
- Removed unused constants.

Bug: 37281200
Bug: 37268410
Test: am instrument -w -e class android.provider.FontsContractE2ETest
      com.android.frameworks.coretests/\
      android.support.test.runner.AndroidJUnitRunner
Test: am instrument -w -e class android.provider.FontsContractTest
      com.android.frameworks.coretests/\
      android.support.test.runner.AndroidJUnitRunner
Test: am instrument -w -e class android.graphics.cts.TypefaceTest
      android.graphics.cts/android.support.test.runner.AndroidJUnitRunner
Change-Id: Ic46c256141d27ca28f30023bcc40f4e1161d5338
2017-04-25 19:40:58 +00:00
Julia Reynolds
a79c37170e Allow some notifications in a group to be muted
Test: cts, runtest systemui-notification
Change-Id: I98b971c496c52f69e039a3a3101f71ac567b538a
2017-04-25 13:41:37 -04:00
TreeHugger Robot
649040c7f6 Merge "Update HardwareBuffer API." into oc-dev 2017-04-21 19:28:32 +00:00
Craig Donner
fd5d331efb Update HardwareBuffer API.
Bug: 37514517
Test: cts-tradefed run cts -t CtsHardwareTestCases -t android.hardware.cts.HardwareBufferTest
Change-Id: I5e381964b780472081ef9a65c3c37f63dbaf1e51
2017-04-20 15:47:49 -07:00
TreeHugger Robot
fb4fb03cc3 Merge "Address API council comments" into oc-dev 2017-04-20 03:53:37 +00:00
Svetoslav Ganov
57ed0ba69d Merge "Address API council comments" into oc-dev 2017-04-19 02:44:18 +00:00
Svetoslav Ganov
345ffa5421 Address API council comments
Test: cookie CTS tests pass

bug:37327624
bug:37325276
bug:37323696

Change-Id: I52b10470759e471629ec6772e115df94482eb341
2017-04-18 16:44:43 -07:00
Svetoslav Ganov
0cb43ef67b Address API council comments
Test: all static shared lib CTS tests pass

bug:37327970

Change-Id: Ie8c4d853da5fa0a6125b9def38831860f79ce53d
2017-04-18 16:44:28 -07:00
Yu Liu
b87243cb43 Remove newly added remove methods in Location and deprecate the old ones, this is the request from the android API council
Test: Existing unit tests still pass.
BUG: 36552859

Change-Id: Ib4cdcef90be3d5b3be329dd780bcb40275b89ef4
2017-04-18 16:12:16 -07:00
Jeff Sharkey
200d72d933 Merge "Storage API polishing." into oc-dev 2017-04-17 22:26:44 +00:00
Jeff Sharkey
789a8fc792 Storage API polishing.
Based on API council feedback, switch to using real UUID objects
instead of Strings.  Since UUID is a general-purpose utility class
that will be passed around quite a bit, add it to Parcel and Bundle.

Define well-known namespaced UUID values for "default" and "primary
physical" storage devices, which will let us annotate a bunch of
things with @NonNull.

Define new extras for MANAGE_STORAGE intent that apps can use to
signal where and how much space they'd like the user to free up.

Test: cts-tradefed run commandAndExit cts-dev -m CtsAppSecurityHostTestCases -t android.appsecurity.cts.StorageHostTest
Bug: 37325923, 35812899, 35806020
Change-Id: I8421b126d680f69141a361c1e77223fe2bf4a325
2017-04-17 12:19:50 -06:00
Julia Reynolds
ad1e9c9825 Remove @removed method
Change-Id: I0b92edcc0440674003694ace9b53cad6124948dc
Fixes: 37340967
Test: make
2017-04-14 12:59:47 -04:00
Peng Xu
3c8c6a4cc9 Address review suggestions for sensor direct report related APIs
Changes inline with bug number

Some improvements about SensorDirectChannel class.
  * Complete the doc about creation of SensorDirectChannel object.
  * Make SensorDirectChannel implements java.nio.channels.Channel.
  * Change isValid() to isOpen().
  * Make close() thread safe.
Bug: 36550285

  * Throw exception on failure of SensorManager.createDirectChannel.
  * Change to use NullPointerException when unexpected null pointer
    is passed in.
Bug: 36555061

  * Move SensorManager.configureDirectChannel() to
    SensorDirectChannel.configure().
  * Format SensorDirectChannel.configure() function doc with
    <pre></pre> to maintain the table structure.
  * Reworded Sensor.isDirectChannelTypeSupported java doc.
Bug: 36555604

Test: pass updated cts SensorDirectReportTest
Change-Id: I447121eaf414cbc94292a109a9d93d2e3c89f8f4
2017-04-13 14:17:11 -07:00
Seigo Nonaka
fe04aa840e Pass weight/italic pair instead of style.
Typeface.NORMAL/BOLD/ITALIC/ITALIC_BOLD is used for specifying relative
from current Typeface. For example

  Typeface face = Typeface.create("serif");
  Typeface thickerFace = Typeface.create(face, Typeface.BOLD);
  Typeface moreThickerFace = Typeface.create(tickerFace, Typface.BOLD);

For the purpose of providing font information, we should use weight/italic
value instead of style in Typeface.
The Columns.STYLE field was kept for preventing runtime crash of demo
apps.

Test: Manually
Change-Id: I732e8ee04a66f61321fc0a98dbfb8fdc0a4dd7a4
2017-04-04 10:12:55 -07:00
Garfield Tan
f6d9507a00 Merge "Add flags for quick viewer to indicate capabilities of a document." into oc-dev 2017-03-31 18:04:54 +00:00
Garfield Tan
ce1d0e9459 Add flags for quick viewer to indicate capabilities of a document.
Replace the QUICK_VIEW_ADVANCED extra.

Also restrict quick viewers not to send file content out of the device.

Test: It builds.
Bug: 36484539
Bug: 36755024
Change-Id: I921230eac6e497a615624202c741ef03432b2690
2017-03-30 17:50:53 -07:00
Aaron Whyte
f830652e97 Split scroll factor into a 2d float.
Test: Existing unit tests, manual sanity check.
BUG=35764483

Change-Id: If6ac121452698747e1f8bc9d4ec0111bb881d4d4
(cherry picked from commit e9956c5c65ecd3aaf7390c10d135749e5adfb344)
2017-03-29 23:34:56 +00:00
TreeHugger Robot
2858ad3a4b Merge "TextClassifier cleanup." 2017-03-27 14:51:13 +00:00
TreeHugger Robot
f3d8d3bd58 Merge "Refactor cache behavior from "atmoic" to "group"." 2017-03-23 06:04:55 +00:00
Jeff Sharkey
b5a35b8181 Refactor cache behavior from "atmoic" to "group".
Using the word "atomic" has too much baggage relating to locking
guarantees, so move to something softer.

Add isQuotaSupported() for CTS tests.

Move CacheQuotaStrategy over to using SparseLongArray, which has a
more efficient memory footprint inside the system server.

Test: cts-tradefed run commandAndExit cts-dev -m CtsAppSecurityHostTestCases -t android.appsecurity.cts.StorageHostTest
Bug: 35812899, 35684969, 36482620
Change-Id: I894f53e6f3bc76c77d1bb18c51db14833df14a49
2017-03-22 21:33:53 -06:00
Julia Reynolds
e071abda78 Notification cleanup
- remove EXTRA_ORIGINATING_USER_ID
- deprecate two icon extra fields; use the getters instead
- rename badge icon methods
- update some unclear documentation

Test: make, cts
Fixes: 33666468
Fixes: 36128288
Change-Id: Ic477259aab5f267fb72ab715d72195d6364cedae
2017-03-22 20:15:20 +00:00
Abodunrinwa Toki
9841ea07c0 TextClassifier cleanup.
- Remove "removed" methods.
- Temporarily log more information about the classification result.

Test: Successfully builds. Manually inspected logs.
Change-Id: I81312ac9992c08ce6137610bd16b339777f8f1fc
2017-03-22 20:13:21 +00:00
Jeff Sharkey
780861f245 More RecoverableSecurityException docs.
Mention convenience methods in class docs, and require a valid
NotificationChannel to be provided to match O best-practices.

Also mention that notifyChange() should be triggered when the action
is finished.

Test: builds, boots
Bug: 34676491
Change-Id: I0e6c6d43a93cbce1a5de02621290cc2ff9423274
2017-03-20 14:38:17 -06:00
Abodunrinwa Toki
4cfda0beef TextClassifier: Introduce LocaleList in the API.
Test: API change. Ensured that tests (see topic) compiles
Bug: 35257733
Change-Id: I036af7948fcd691b8a7de586a9cc1b3165946f8a
2017-03-07 14:25:21 +00:00
Jeff Sharkey
4190575960 Merge "Delete @removed APIs that never shipped." 2017-02-27 01:45:44 +00:00
Jeff Sharkey
dd9bda81f6 Delete @removed APIs that never shipped.
These were never part of any public API level, so apps should never
have been using them.

Test: builds, boots
Bug: 31241513
Change-Id: I4fc8f5c325da56694a5db98acc995a22d4947805
2017-02-24 13:41:20 -07:00
Jeff Sharkey
bb4988ad7d Improve service docs around user unlocking.
Also delete some @removed methods that never shipped to reduce
confusion.

Test: builds, boots
Bug: 30434803
Change-Id: I18773182f62f0f62bd4e36c9c3098372483a374f
2017-02-24 09:02:53 -07:00
Jeff Sharkey
d5d5e926eb Clear cache space when allocating bytes.
Fleshes out remainder of allocation implementation, where we offer
to clear cached data to satisfy the allocation request.  To prevent
abuse, we never let apps allocate into either the minimum cache space
or low storage space.

Clean up quota APIs to require the caller to pass in the path they're
interested in, and we resolve the underlying filesystem for them.

Defines settings that can be used to tweak the minimum cache space.

Test: builds, boots
Bug: 34690590
Change-Id: I85bc07399f91ee4aa568a8a54c615646bf748ad4
2017-02-21 11:50:55 -07:00
Lorenzo Colitti
5bd8014265 Merge "Remove requestRouteToHost and {start,stop}UsingNetworkFeature." 2017-01-11 03:52:21 +00:00
Lorenzo Colitti
2187df7515 Remove requestRouteToHost and {start,stop}UsingNetworkFeature.
These APIs have been deprecated since L, and since M have thrown
IllegalArgumentException for apps targeting M or newer.

Test: API check passes.
Bug: 33607472
Change-Id: Ie582cac3872be21c51e1e37d16d7cfac496ed3e4
2017-01-05 17:39:21 +09:00
Derek Sollenberger
b29b16e542 Remove clipRegion from the public API.
This API is difficult to support for printing and has other negative
effects as it does not respect the current matrix/clip.

Test: compile
Bug: 14650725
Change-Id: I71f9bd687d446c7ce8910d755421aad8e09458db
2017-01-04 14:57:43 -05:00
Wyatt Riley
a2bbfbcf89 Removing @removed methods and constants
Several methods, plus a few hashmaps,
helper classes, and some constants
existed for an early builds
of NYC, and were marked @removed, and are
here finally removed.

Bug: 28208055
Change-Id: If650d83c0dc573e922342d09360ecf9a5bb0c98a
Fixes: 28208055
Test: GMaps, AndroiTS GPS Test, GnssLogger & CtsVerifier
      All run fine on a Pixel
2016-12-23 13:18:16 -08:00
Derek Sollenberger
dcc3630100 Remove Rasterizer and its subclasses from the public API.
Test: compile
Bug: 14650725
Change-Id: I99e1942d4d1b85f4efdcb3faf3fee1aa6c839b7e
2016-12-12 10:53:58 -05:00
Alex Klyubin
5e86d951a7 Remove android.net.PskKeyManager
android.net.PskKeyManager does not work with upcoming TLS 1.3.
The class does not appear to be used by any Android apps and is thus
likely to be completely removed in the future.

Bug: 30978706
Test: make && make cts
Change-Id: Id9bae20362c5909e4621cdb00102bfee09d970ec
2016-09-27 11:24:32 -07:00
Svet Ganov
77df6f315d Remove permission review build property - framework
Change-Id: Ifcfd436f2d57a6006ef804292d2875434e4669da
2016-08-17 14:52:26 -07:00
Adam Lesinski
7317f30939 Remove private package from removed.txt
Change-Id: I71e764e5e34b7bd671e208fa20dec06956df59b0
2016-07-27 15:19:24 -07:00
Jeff Sharkey
a0d2e12fe0 resolve merge conflicts of 0c26c32 to master
Change-Id: I2398a72d7a3575743e5948bc16b1b8582ccf106b
2016-06-03 15:00:10 -06:00
Michael Wright
c38a203376 Revert "Revert "Finalize resource IDs for N.""
This reverts commit a5c9ca4f07418b80ac99a3d23df012d77faa2bc4.

Bug: 28810934
Change-Id: I31816ab5470b84f85c8416312b5ac39884b8cc9a
2016-05-26 17:38:11 +01:00
Michael Wright
9ed5eefc28 Revert "Finalize resource IDs for N."
This reverts commit 7c8e76f87de28acc19935083a0f502df83c4a023.

Bug: 28810934
Change-Id: I3a61bb0c2364909480045dd40adba6445d6afabd
2016-05-26 17:38:06 +01:00
Michael Wright
7c8e76f87d Finalize resource IDs for N.
Bug: 28810934
Change-Id: If68bfb46cc5fa2d5ea0ee613689198e1ea42dce7
2016-05-26 17:35:28 +01:00
Daichi Hirono
86c1a9bf60 Remove MTP API marked as @removed.
BUG=28146379

Change-Id: I4f0a380941663eac423f8a5633447f1eceb516cb
2016-05-26 16:39:21 +09:00
Antonio Cansado
904237f839 Cleaning up NetworkStatsManager.
- Throwing SecurityExceptionand and IllegalArgumentException instead of null for new APIs
- removing @removed APIs

Bug:27530098,27379882
Change-Id: Ifbe65bfc5051aa33aff2baa22cfa8e67b0f7c358
2016-05-25 11:07:41 -07:00
Jean-Michel Trivi
602dc777c5 Remove deprecated AudioManager.AudioRecordingCallback method
Remove AudioRecordingCallback.onRecordingConfigChanged(
         AudioRecordingConfiguration[] configs)

Bug 28819230

Change-Id: I3b85bb9313267499ac407099939b5889bdba996b
2016-05-24 12:11:59 -07:00
Jean-Michel Trivi
f04fab160a Recording activity notification: return list of configuration
Use a list of configurations instead of an array

Bug 28819230

Change-Id: Ia4a3cdabf8337cfb98abe4d0055d497bcab8a5ee
2016-05-23 09:44:58 -07:00
Andrii Kulian
f66a83db41 Rename minWidth/Height attributes
Rename WindowLayout#minimalWidth and #minimalHeight to #minWidth
and #minHeight to be consistent with other APIs.

Bug: 28775586
Change-Id: Ib7dc26318c4391693ef23f908b4d6090138dd0d7
2016-05-17 13:00:53 -07:00
TreeHugger Robot
a1e4cbe211 Merge "Remove onUhandledInputEvent API." into nyc-dev 2016-05-16 15:18:20 +00:00
Tingting Wang
752129929f Merge "Rename CONTACT_METADATA_SYNC GService Flag." into nyc-dev 2016-05-12 17:11:44 +00:00