Commit Graph

12362 Commits

Author SHA1 Message Date
TreeHugger Robot
02aca1058f Merge "Initial implementation of AutofillManager.setAugmentedAutofillWhitelist()" 2019-02-21 00:01:56 +00:00
TreeHugger Robot
6944910037 Merge "Add CompositionSamplingListener" 2019-02-20 23:44:26 +00:00
TreeHugger Robot
1671308c29 Merge "API adjustments for Picture serialization discussion" 2019-02-20 18:00:28 +00:00
Mathew Inwood
f906a38eed Merge "Move the right method to max-sdk-o list." 2019-02-20 17:43:42 +00:00
TreeHugger Robot
4cac1f42f0 Merge "Move TextClassifier.getLocalTextClassifier() API." 2019-02-20 16:40:21 +00:00
TreeHugger Robot
f7612ac846 Merge "Changes on the ContentCaptureContext APIs." 2019-02-20 15:51:59 +00:00
Alan Viverette
db9c27cb7a Merge "Public API for statically accessing global list of window views" 2019-02-20 14:59:12 +00:00
Adrian Roos
9b963d3ce4 Add CompositionSamplingListener
Adds a facility to sample the median luma in a region
of the SurfaceComposer's result.

Test: atest CompositionSamplingListenerTest
Bug: 124305231
Change-Id: I78eececa9aef420f488a860f4e6891d4af84d27f
2019-02-20 15:16:36 +01:00
TreeHugger Robot
fe71582e23 Merge "Introduce a way to turn a fullscreen window into freeform" 2019-02-20 09:43:51 +00:00
Yunfan Chen
d967af828b Introduce a way to turn a fullscreen window into freeform
Change the exitFreeformMode to toggleFreeformMode. Now the original
maximize button will work as maximize/restore button.

Test: go/wm-smoke
Test: Manual test.
Bug: 117075771
Bug: 124475503

Change-Id: I268d053ed0e665b8ac5e56019c6ae8f8b7ee1317
2019-02-20 15:51:40 +09:00
Felipe Leme
72e83d8c3d Changed ContentCaptureManager API so service can only disable itself.
To re-enable, it will need to launch a Settings intent
(Settings.ACTION_REQUEST_ENABLE_CONTENT_CAPTURE).

Bug: 123286662
Test: atest CtsContentCaptureServiceTestCases

Change-Id: I0dd03013aba645c188af4034e530492d8294180e
2019-02-19 09:29:14 -08:00
Mathew Inwood
8e82865436 Move the right method to max-sdk-o list.
The DisplayListCanvas override was on the dark grey list in P, not the
View override.

Test: m
Bug: 123987101
Change-Id: Ibc1503a8b5fe7dfe797835c972288c4b98362b65
2019-02-18 10:55:08 +00:00
Felipe Leme
044c63b367 Changes on the ContentCaptureContext APIs.
- Replaced URI by a generic ID
  (which is a new class LocusId, and required)
- Createad a new Intent.ACTION_VIEW_LOCUS action
  (and Intent.EXTRA_LOCUS_ID extra)
- Removed ContentCaptureContext.getAction()
  (so the only "supported" action is ACTION_VIEW_LOCUS)
- Made the ContentCaptureContext getters public
  (getId(), getExtras())

Test: m update-api
Test: atest CtsContentCaptureServiceTestCases \
      CtsContentTestCases:LocusIdTest \
      FrameworksCoreTests:android.view.contentcapture.ContentCaptureEventTest

Bug: 123577059
Fixes: 124266664

Change-Id: Id4c28f056eb7a24dd083303ffdea7cf662cefac2
2019-02-15 20:44:35 -08:00
Felipe Leme
e8eae9d420 Initial implementation of ContentCaptureService.setContentCaptureWhitelist()
For now it only whitelists packages, not activities.

Test: atest CtsContentCaptureServiceTestCases

Bug: 122595322

Change-Id: I5beb9b027eb704510e68f3af15e84e14bda07eb2
2019-02-15 20:00:49 -08:00
TreeHugger Robot
2188365b44 Merge "Annotated mTheme field on ContextThemeWrapper with maxTargetSdk P" 2019-02-16 03:48:19 +00:00
Felipe Leme
80e7bf114d Initial implementation of AutofillManager.setAugmentedAutofillWhitelist()
For now it only whitelists packages, not activities.

Test: atest CtsAutoFillServiceTestCases:android.autofillservice.cts.augmented.AugmentedLoginActivityTest

Bug: 123100824

Change-Id: I043f4a22684fcdac7409393c208c2c1e6d987c5e
2019-02-15 17:57:58 -08:00
Felipe Leme
d32d8f6f3c Added DeviceConfig properties to fine tune ContentCapture:
- DEVICE_CONFIG_PROPERTY_MAX_BUFFER_SIZE
- DEVICE_CONFIG_PROPERTY_IDLE_FLUSH_FREQUENCY
- DEVICE_CONFIG_PROPERTY_TEXT_CHANGE_FLUSH_FREQUENCY
- DEVICE_CONFIG_PROPERTY_LOG_HISTORY_SIZE
- DEVICE_CONFIG_PROPERTY_LOGGING_LEVEL

Test: manual verification
Test: atest CtsContentCaptureServiceTestCases

Bug: 123096662
Fixes: 121044064
Fixes: 121044306

Change-Id: I08623516bb7ebbe9c900987be853f4f395250016
2019-02-15 17:32:04 -08:00
TreeHugger Robot
fe09cbef5a Merge "ContentCaptureManager should be null when the feature is disabled." 2019-02-16 00:57:04 +00:00
Alan Viverette
1761cfac39 Public API for statically accessing global list of window views
Android Studio's UI inspection tool needs access to the currently displayed
window(s) via publicly-accessible APIs given only a classloader -- it does
not have any activity or app Context.

Bug: 124516440
Test: atest WindowInspectorTest
Change-Id: I960165813c260ac8f8e17cc163fabf65b1417480
2019-02-15 16:17:30 -05:00
John Reck
d9425659af API adjustments for Picture serialization discussion
Fixes: 124315734
Test: none
Change-Id: Ie1c610ae5536225f1ba454235be509f1c7e70bab
2019-02-15 12:32:31 -08:00
Nader Jawad
a1eef72673 Annotated mTheme field on ContextThemeWrapper with maxTargetSdk P
Added ContextThemeWrapper#setTheme(Theme) method to programmatically
assign the theme without using a resource id

Change-Id: I043253e65a535abdf8d89d9421d2cff2b41bdb05
Fixes: 123768723
Test: Added CTS test to verify setTheme
2019-02-15 19:06:51 +00:00
Felipe Leme
d49d52c0ad ContentCaptureManager should be null when the feature is disabled.
Test: manual verification using logcat and dumpsys
Test: atest CtsContentCaptureServiceTestCases

Fixes: 124475449

Change-Id: I699de127bf9e61ba187eb129c38d243d5fc93f1c
2019-02-15 10:32:45 -08:00
TreeHugger Robot
3a5211e744 Merge "Changed ContentCaptureService.setContentCaptureWhitelist() to use Set instead of List." 2019-02-15 04:20:23 +00:00
Felipe Leme
7a3c9f5324 Changed ContentCaptureService.setContentCaptureWhitelist() to use Set instead of List.
(Same for Augmented Autofill)

Bug: 122595322
Test: m update-api

Change-Id: I6753ce2567801da148682c0ccbad7f6abc4d1ecc
2019-02-14 14:13:56 -08:00
John Reck
989bb3714f Merge "Make HardwareRenderer public API" 2019-02-14 20:40:13 +00:00
TreeHugger Robot
1df6e435b0 Merge "Removed unused APIs." 2019-02-14 16:51:29 +00:00
Felipe Leme
0552f41c4e Merge "Add new ContentCapture APIs to let apps change the ContentCaptureContext." 2019-02-14 15:26:27 +00:00
TreeHugger Robot
e3e53162cb Merge "Fix Autofill PartitionedActivityTest fail." 2019-02-14 02:38:39 +00:00
Felipe Leme
3f1e2318e6 Removed unused APIs.
Plus fixed a few minor TODOs.

Test: atest AugmentedLoginActivityTest
Test: m update-api

Bug: 122654591
Fixes: 123233342

Change-Id: Ie5040077255ffab8fee019ca6a0a122fe9f2e03d
2019-02-13 13:21:27 -08:00
TreeHugger Robot
b1a0da1098 Merge "Update View#getAttributeResolutionStack to take @AttrRes" 2019-02-13 18:36:24 +00:00
Nader Jawad
9b31762790 Merge "Added public API alternatives to reflective calls on ScrollBarDrawable" 2019-02-13 17:55:48 +00:00
TreeHugger Robot
5978e065ab Merge "Add android.view.DisplayAddress" 2019-02-13 17:23:58 +00:00
Cătălin Tudor
b7c074fbce Merge "Fix hidden usage sConstructorMap" 2019-02-13 10:44:36 +00:00
Andrey Kulikov
81aac219c9 Merge "Restrict platform's GhostView and unhide a method needed for a backport" 2019-02-13 10:44:03 +00:00
Rhed Jao
4b87f31952 Fix Autofill PartitionedActivityTest fail.
Bug: 124235900
Test: atest PartitionedActivityTest
Change-Id: Ie058ff4d3162e969a727b3fa72bca12475076ae9
2019-02-13 17:50:38 +08:00
TreeHugger Robot
96e278d6c4 Merge "Restrict usage of AccessibilityManager::mIsEnabled after P" 2019-02-12 22:53:12 +00:00
Nader Jawad
93aeba8c52 Added public API alternatives to reflective calls on ScrollBarDrawable
Added public setter/getter APIs on View to set/get the track/thumb
Drawables for the vertical and horizontal scroll bars to support
configuring scrollbars programmatically in addition to xml
attributes

Change-Id: Ic0b42742e8a795fe616887369dd0e592cde5c2fa
Fixes: 123769505
Test: Added View.java test cases to verify new setter/getters
2019-02-12 14:31:49 -08:00
Aurimas Liutikas
e2112310c6 Update View#getAttributeResolutionStack to take @AttrRes
getAttributeResolutionStack was not enough for cases where View
subclasses called obtainstyledattributes with different defStyle values.

Bug: 111439551
Test: updated CTS tests
Change-Id: I81403bdfd5e6f6b34ce34824689d0cef9c32ae44
2019-02-12 13:40:02 -08:00
Abodunrinwa Toki
324572e747 Move TextClassifier.getLocalTextClassifier() API.
In the future, we think the TextClassifier is going to run in an
external process. This CL moves the getLocalTextClassifier() API so
that we don't have to guarantee this to apps.
OEMs implementing TextClassifierServices however will want access to
this API so this CL effectively moves the the API from where apps
typically look for a TC (we prefer apps to call getTextClassifier()
instead) to where TCS implementations are most likely to be accessing
such APIs. The method is also renamed appropriately to what it will be
long term (i.e. the default TC implementation rather than as the local
TC).

Bug: 123681286
Test: atest core/tests/coretests/src/android/view/textclassifier
Test: atest cts/tests/tests/view/src/android/view/textclassifier/cts
Test: adb shell am instrument -w -e class android.textclassifier.TextClassifierPerfTest com.android.perftests.core/androidx.test.runner.AndroidJUnitRunner
Change-Id: I685e2b5263ffddbe301256fc2ed0d6254c3357ed
2019-02-12 20:56:58 +00:00
Felipe Leme
4eecbe6e3c Add new ContentCapture APIs to let apps change the ContentCaptureContext.
Test: atest CtsContentCaptureServiceTestCases:android.contentcaptureservice.cts.LoginActivityTest#testSimpleLifecycle_changeContextOnCreate \
   CtsContentCaptureServiceTestCases:android.contentcaptureservice.cts.LoginActivityTest#testSimpleLifecycle_changeContextAfterCreate
Test: atest FrameworksCoreTests:android.view.contentcapture.ContentCaptureEventTest

Bug: 124266664

Change-Id: I0348e81e1b2bac01363cf615d2ab32e5bab8aee1
2019-02-12 11:31:06 -08:00
Dan Shi
18a52fb0c7 Remove CtsViewTestCases in TEST_MAPPING file
The test config has an option to use package filter, which does not
work with another TEST_MAPPING which has the same test but use a
class filter.
startop/view_compiler/TEST_MAPPING

Bug: 124248633
Test: none
Change-Id: Id989d9df8983e7a08be38616e92e10f70fe4846a
2019-02-12 09:33:07 -08:00
Matvei Malkov
6689e620a6 Restrict usage of AccessibilityManager::mIsEnabled after P
Setting this field with reflection leaves AccessibilityManager in
improper state. Restrict access to this field in future apis

Bug: b/124052733
Test: accessibility tests passed
Change-Id: I776e1092ab33cf9660f593a22585695c17852e1e
2019-02-12 15:41:54 +00:00
Andrey Kulikov
7c4e693104 Restrict platform's GhostView and unhide a method needed for a backport
Bug: 117521193
Bug: 123768642
Test: added a cts test for the new method
Change-Id: If933dbe16e756bf4e32d1cf43d9d3ecc67e37174
2019-02-12 15:29:14 +00:00
Mathieu Chartier
bd3810b28f Merge "Revert "Revert "Add view inflation device config property""" 2019-02-12 11:11:33 +00:00
Cătălin Tudor
e61fc256d3 Fix hidden usage sConstructorMap
In LayoutInflater, sConstructorMap was marked with @UnsupportedAppUsage.

After doing some research, the main reason for accessing this appears to
be related to classloaders (fixed in CL=839342, method=verifyClassLoader).
As this is fixed and creating a public API for a cache doesn't seem
apropriate, dark grey listing it seems the best solution.

Bug: 123769490
Test: android.view.cts.LayoutInflaterTest
Change-Id: I104ce17bb4083f7049bbb512090b31f8360cb23b
2019-02-12 10:28:47 +00:00
Yohei Yukawa
1466e4a4e7 Hide InputMethodManger.showSoftInputUnchecked() from Q+ apps
This is a follow up CL to my previous CL [1], which declared that
InputMethodManger.showSoftInputUnchecked() was deprecated and should
have never be used any more.

At that time, however, we could not simply remove that hidden API
because android.support.v7.widget.SearchView had been used it via
reflection and the reflection code was already statically linked into
many apps in the ecosystem.  What we could do at that time was getting
rid of this hidden API dependency from support lib v26 [2] and making
sure that a clear warning was shown in logcat if apps were still using
older support lib [3].

Almost two years later now, it's probably time to step forward towards
true deprecation of this hidden API.  With this CL, apps that target
Q+ can no longer call this method.

 [1]: I20983e4ce1d625e098a8c2335ce75994cfa43235
      5cfc1b4c10
 [2]: Iaac4673a85c141c787b96fb39806346ccfb85fb3
      fd44fffced7cce36c1ce0d62dfe2542aa6a7c6e9
 [3]: If01316a0c2a210f9ea03b53700d0ef651955ba9c
      101ae464fc

Bug: 36015425
Fix: 123768499
Test: make -j checkbuild
Change-Id: Ie7362f62f1e947ee5a21b90f5150c69f2970d73d
2019-02-12 01:42:56 -08:00
Phil Weaver
f1c246619f Merge "Add owners for accessibility" am: bbbeba3c02 am: a525ea4436
am: c36e36b87e

Change-Id: Iaa5653b02e99a149186a99f3fda28111263aa2ad
2019-02-11 17:12:54 -08:00
Phil Weaver
c36e36b87e Merge "Add owners for accessibility" am: bbbeba3c02
am: a525ea4436

Change-Id: Ia828c34be1f1dac6ea58ce0e68cf032f058dbb0b
2019-02-11 16:53:13 -08:00
TreeHugger Robot
2e71c58863 Merge "Exposed even moar DeviceConfig APIs for testing." 2019-02-12 00:47:56 +00:00
Phil Weaver
a525ea4436 Merge "Add owners for accessibility"
am: bbbeba3c02

Change-Id: I099187d207d5610bc79d630f105bff2de41481c3
2019-02-11 16:34:27 -08:00