Commit Graph

10097 Commits

Author SHA1 Message Date
Selim Cinek
4f3463290b Merge "Increased the collapsed size of messaging notifications" 2017-02-02 23:59:08 +00:00
Esteban Talavera
3355950785 Merge "Affiliated profile owners can set lock task packages" 2017-02-02 14:15:55 +00:00
Narayan Kamath
ff5659fbc3 Revert "Call ActivityCallbacks after corresponding activity methods"
This reverts commit 660cf30e21.

bug: 34415265
bug: 34914977
Test: chrome launches

Change-Id: I170365fd47313bafb0d722e6d55ee119336137c4
2017-02-02 13:55:31 +00:00
Felipe Leme
5523f9a2fc Merge "Improved AutoFill Save workflow." 2017-02-02 02:05:32 +00:00
TreeHugger Robot
edae71777f Merge "Fix setting null target fragments" 2017-02-01 20:54:55 +00:00
Julia Reynolds
986c32dafe Merge "Deprecate notification fields" 2017-02-01 20:24:24 +00:00
Felipe Leme
0200d9ea15 Improved AutoFill Save workflow.
Currently, the onProvideAutoFillStructure() methods can be called
twice: to auto-fill an activity and to save the activity's data
in the service.

The problem with this approach is that when the save workflow is
called, the activity might have been gone. Hence, a proper approach
is to keep the initial AssistStructure data in the system_service
memory, watch for view changes, and then passed the new structure
back to the AutoFillService.

A side effect of this change is that we need another way to determine
if the view is sanitized or not. For "standard" views, that will be
defined based on whether the view content come from a resource or not,
but that logic is not implemented yet (for now, all views will be
considered sanitized, except for TextView passwords). For "custom"
views (such as WebView), this logic is responsibility of the view
implementation, through the newChild() method, which now takes a
flag (whose value could be AUTO_FILL_FLAG_SANITIZED for sanitized
views).

The SaveCallback.onSuccess() method was simplified: it does
not need a list of saved ids anymore the auto-fill UI will not use it
anymore.

Another side effect is that the Save notification is gone - until
it's attached again, it can be test by using:

    adb shell cmd autofill save

Finally, hook AutoFillUI on ACTION_CLOSE_SYSTEM_DIALOGS events.

BUG: 33269702
BUG: 31001899
Test: manual verification
Test: CtsAutoFillServiceTestCases passes
Change-Id: I907a7e21d1b3cd1ab6dec3a08d144a52655da46f
2017-02-01 11:00:15 -08:00
Adam Powell
0621742d3c Fix setting null target fragments
Bug 34869013
Test: CTS

Change-Id: Ibeed66f9a889a8e395bfabedcf22aebcbb848908
2017-02-01 10:45:12 -08:00
Sergei Vasilinetc
40c509ff0f Merge "Call ActivityCallbacks after corresponding activity methods" 2017-02-01 18:02:34 +00:00
Esteban Talavera
bdcada9762 Affiliated profile owners can set lock task packages
Mentioned that in the documentation, cleaned up the code
a bit and added unit tests

Bug: 34614754

Test: runtest -c com.android.server.devicepolicy.DevicePolicyManagerTest    frameworks-services
Change-Id: I91232bbe494398015094ab977c6a2adce339811f
2017-02-01 15:02:22 +00:00
Julia Reynolds
a33f5c4312 Deprecate notification fields
And move references to the deprecated fields to
NotificationRecord for testability.

Test: runtest systemui-notification
Change-Id: If3910dc78297ad66679b1efa380315127261a018
2017-02-01 09:56:00 -05:00
Phil Weaver
7da087d87d Merge "Accessibility can capture fingerprint gestures" 2017-02-01 02:01:44 +00:00
Adam Powell
adfd62c484 Fragment grab bag!
* Fragment#isStateSaved: report whether a given fragment has been
  through state save within its given FragmentManager. This will
  additionally echo the state of its child FragmentManager, indicating
  whether it is safe to perform transactions without losing state.

* Fragment#setArguments can now be called at any time before a
  fragment's state is saved, not just before an internal index is
  assigned. This fixes an issue with assigning arguments during
  fragment inflation in some code paths.

* FragmentTransaction#postOnCommit: Add a Runnable to a
  FragmentTransaction that will be executed once the operations in the
  transaction have been fully executed. Transaction optimization may
  mean that other transaction ops could run before this is executed,
  or that specific operations from this transaction were optimized
  out. (e.g. a fragment in this transaction was added, but then
  removed in a subsequent transaction before pending operations were
  executed.) This may not be used for transactions added to the back
  stack, as we cannot persist the runnable for later to guarantee
  running it when the transaction is reversed.

Test: CTS
Change-Id: I4eb90588135e30f287c6487aa62ebda231f3dad3
2017-01-31 14:58:17 -08:00
Phil Weaver
27fcd9c97a Accessibility can capture fingerprint gestures
Bug: 27148522
Test: Unit tests for two new classes in this CL, CTS in
linked CL.
Change-Id: Icb5113e00b1f8724814263b3cc7f72fe4a6f0b41
2017-01-31 14:27:09 -08:00
sergeyv
660cf30e21 Call ActivityCallbacks after corresponding activity methods
Test:  android.app.cts.ActivityCallbacksTest
bug:34415265
Change-Id: I1d8dd3a5c564c2036174a686aeb0eaf0883c0a55
2017-01-31 10:50:55 -08:00
TreeHugger Robot
53ff0bdfb9 Merge "Primary navigation fragments" 2017-01-31 18:40:43 +00:00
Selim Cinek
7d1009b3bd Increased the collapsed size of messaging notifications
Messaging notifications now get an increased boost in size,
since those are usually important to the user.

Test: existing tests pass
Bug: 34469375
Change-Id: Idfc2d2403b04c4c2d17b821e3ccbbbd48d31654d
2017-01-31 10:26:03 -08:00
TreeHugger Robot
c869ebff63 Merge "Add instant cookie APIs" 2017-01-31 03:17:49 +00:00
Dianne Hackborn
a09a31f99f Merge "Remove some unused code around process state reporting." 2017-01-31 01:55:58 +00:00
Svetoslav Ganov
096d304ae3 Add instant cookie APIs
This change adds APIs for instant apps to store cookie data
that is presisted across instant installs and across the
upgrade from an instant to a standard app. Standard apps
can use the cookie APIs but when they are uninstalled the
cookie is also deleted. The cookies are kept longer than
the instant apps as they are much smaller - 16KB by default.
We can change the cookie size via a system setting i.e.
after we ship we can increase size if needed.

We also add internal APIs to surface information about
installed and uninstalled instant apps which should be
used for showing them in the UI. For this puporse we store
the icon, permissions, and label of uninstalled apps. If
the app is re-installed we drop this meta-data but keep
the cookie around. If we have cookie data stored and the
signing cert of the app changes when it gets re-intalled
we wipe the cookie.

Test: CTS tests pass; hiddent APIs tested manually

Change-Id: If145c0440cc61a5303e2cbb70228d235d36037a5
2017-01-30 17:52:14 -08:00
Dmitri Plotnikov
e122c245a9 Merge "Protecting TvExtender from being stripped by lightenPayload()" 2017-01-31 00:17:21 +00:00
Julia Reynolds
cb07efbf74 Merge "Add audio attributes to notificationchannel" 2017-01-30 19:37:04 +00:00
Dmitri Plotnikov
2228136171 Protecting TvExtender from being stripped by lightenPayload()
Test: Verified manually that TvExtenders actually
arrive in LeanbackLauncher
Change-Id: I42bfc340f7e92bc15243f66c6ae24a330d569262
2017-01-30 11:22:06 -08:00
Edman Anjos
9e62c3111e Update in DPM delegation documentation.
Add note on DPM#setDelegatedScopes documentation regarding the
broadcast sent to the delegate package to notify its new scopes; and
change the admin ComponentName annotation to @Nullable in
DPM#getDelegatedScopes.

Bug: 33099995
Test: cts-tradefed run cts-dev --module CtsDevicePolicyManagerTestCases --test com.android.cts.devicepolicy.MixedDeviceOwnerTest#testDelegation
Change-Id: I28fe3a631c05a9e6b8dae766ce6c42881f2e3a00
2017-01-30 17:11:40 +01:00
Julia Reynolds
619a69f722 Add audio attributes to notificationchannel
Test: runtest systemui-notification, cts, manual
Change-Id: I33b5a67190409fe2fc2bc7e2cbbd67ea38bc0655
2017-01-30 08:55:31 -05:00
Chet Haase
b64e777f6c Add methods to query animation state
Testing utilities want the ability to know whether things in the UI
are in flux and they need to wait before testing on-screen values.
These changes (a subset of what's needed, but will have to do for
a start) allow querying of ActivityTransitions and ProgressBar, two
common/difficult pieces in the puzzle.

Test: CTS tests at ag/1835467
Bug: 30978257 Provide view transition Api to prevent flaky tests

Change-Id: If63b3d0dde2178d826ac1dbfad0fc50e5ed9a780
2017-01-30 12:57:43 +00:00
Esteban Talavera
b3231029b5 Merge "Profile owners on a user can communicate with device owners" 2017-01-30 11:33:38 +00:00
Adam Powell
5f3a05c15f Primary navigation fragments
Port of I82cd22cda6e9ee22fe293c36859e99f49d36a129 from frameworks/support

Add API to track the "primary navigation fragment" for a
FragmentManager. This allows designating one active fragment in a
FragmentManager as the intended nested recipient of navigation actions
such as popping the back stack.

The FragmentManager popBackStack methods will now delegate to the
child FragmentManager of the current primary navigation fragment first
before trying to pop its own back stack. This can only happen if a
back stack transaction id or back stack entry name is not provided to
the pop operation, as these names and ids are namespaced to each
individual FragmentManager.

Primary navigation fragments are set as part of a FragmentTransaction
and follow the associated expectations. Transactions added to the back
stack will be fully reversed when popped, restoring the previous
primary navigation fragment for the FragmentManager. If a primary
navigation fragment is removed from the FragmentManager, the primary
navigation fragment will be set to null.

Bug: 30596279
Test: CTS
Change-Id: Ied7c1515f27142d6f4cd523f16eb35d38a2a2380
2017-01-27 16:51:03 -08:00
TreeHugger Robot
977b106de6 Merge "Notification: Fix Ambient view text color" 2017-01-27 20:17:28 +00:00
Adrian Roos
72171629e6 Notification: Fix Ambient view text color
Change-Id: Ib45e2288932939896bb05fc1dc606e3551dd951d
Test: Trigger Ambient Display, check text is readable.
Fixes: 34767438
2017-01-27 10:42:20 -08:00
Julia Reynolds
1af50e2da1 Merge "Show channel groups in settings" 2017-01-27 18:22:15 +00:00
Paul Navin
7d0f5e8d40 Add hidden API for whether permission review mode is on. am: 7b89a7b1f7 am: 7c230c6f3c
am: dd91db5515

Change-Id: I936449f717e3c2919622181c9068ec8a48b452ad
2017-01-27 17:03:38 +00:00
Paul Navin
dd91db5515 Add hidden API for whether permission review mode is on. am: 7b89a7b1f7
am: 7c230c6f3c

Change-Id: I89c9a580a96d0f69ed30cad9ec2e4f9c215a403b
2017-01-27 16:59:33 +00:00
Paul Navin
7c230c6f3c Add hidden API for whether permission review mode is on.
am: 7b89a7b1f7

Change-Id: I925b6de9f79850dcc816a73357d1d589eeac6333
2017-01-27 16:55:03 +00:00
Victor Chang
98607130fe Update doc to allow system image app to display terms in ManagedProvisioning
Bug: 34320095
Test: javadoc update only. built successfully
Change-Id: I9f023a12adbbd5f3d5ed3594508642b8dd573896
2017-01-27 14:04:19 +00:00
Julia Reynolds
f02562aeee Show channel groups in settings
Empty groups shouldn't be visible to client code.

Test: runtest systemui-notification
Change-Id: I319b035886ce1bd4b6839ebf46a2c3be7b2387cf
2017-01-27 08:51:45 -05:00
The Android Automerger
7bc2aebd53 Merge commit '48a1136c8b3000c651e8bcd86325acd1dce6e4ec' into nyc-mr1-dev-plus-aosp
* commit '48a1136c8b3000c651e8bcd86325acd1dce6e4ec':
  Implement metered tracking for NetworkStats summary queries.
2017-01-27 06:39:41 +00:00
The Android Automerger
53095bb5bd Merge commit 'a19056c35d16ddb5a6c1d3343729701b8939f1e1' into nyc-mr1-dev-plus-aosp
* commit 'a19056c35d16ddb5a6c1d3343729701b8939f1e1': (35 commits)
  NetworkMonitor: send one DNS probe per web probe
  NetworkMonitor metrics: add first validation information
  APF: also drop any ICMPv6 RSs
  ConnectivityServiceTest: fix testAvoidBadWifiSettings
  Fix ConnectivityServiceTest testRequestBenchmark
  Switch over to new "time.android.com" NTP pool.
  Define API for metering network stats buckets.
  Refactored NetworkStatsServiceTest to use Mockito instead of EasyMock.
  Use @Ignore to explicitly disable a @Test method.
  Fixed NetworkStatsServiceTest and converted it to JUnit4.
  VPN network stat accounting changes.
  ConnectivityThread: use lazy holder idiom
  ConnectivityManager: use ConnectivityThread looper
  ConnectivityManager: a simpler CallbackHandler
  Indicate the NsdServiceInfo attributes are only filled in for a resolved service.
  Add a null check for the OnStartTetheringCallback.
  TokenBucket for rate-limiting and throttling
  IpConnectivityMetrics reads buffer size in settings
  CaptivePortalLogin: set mixed content policy to compatibility.
  Add IP conn metrics to dumpsys and bug reports
  ...
2017-01-27 06:39:05 +00:00
TreeHugger Robot
e682445698 Merge changes from topic 'session_refactoring'
* changes:
  Adds autofill save ui
  Moar AutoFill Framework refactoring...
2017-01-27 03:46:36 +00:00
Paul Navin
7b89a7b1f7 Add hidden API for whether permission review mode is on.
BUG: 34240393
Change-Id: I68e55767a7da1d457a6cedd210aac9e339fb996c
2017-01-27 03:42:32 +00:00
TreeHugger Robot
11c80cf32b Merge "Lifecycle guarantees for target fragments" 2017-01-27 02:45:17 +00:00
TreeHugger Robot
416903e7c4 Merge "Unhide ApplicationInfo.volumeUuid." 2017-01-27 01:34:40 +00:00
Adam Powell
ab209a63a2 Lifecycle guarantees for target fragments
Ported from frameworks/support change id
I824eb312fbdfd6b548fe94aa2cd5b03afbaa97c7

When a target fragment was set using Fragment#setTargetFragment, all
bets were off, especially when restoring from instance state. Order of
lifecyle initialization was undefined meaning that two bugs could
occur, both of which manifested as the target fragment was not
initialized by the time the referring fragment's onCreate ran. One
could happen if the target fragment is on the back stack, the other
could happen if the target fragment was ordered unfortunately in
FragmentManager implementation details. (!)

Fix both by guaranteeing that any target fragment gets pushed forward
to at least the CREATED state before we dispatch any lifecycle events
for the referring fragment.

Add some sanity checks that try to keep developers from setting target
fragments across different FragmentManagers or from creating target
cycles, both of which are bad ideas.

Bug: 33653458
Test: CTS FragmentLifecycleTest
Change-Id: If624d4665d29e205d37b9b384322e64d6d6d3615
2017-01-27 00:52:26 +00:00
Jeff Sharkey
6112860c5c Unhide ApplicationInfo.volumeUuid.
Apps need it to interact with the new StorageStatsManager APIs.

Test: builds, boots
Bug: 34723750
Change-Id: I274d5bd425cd401e10647959ba18f9956628d810
2017-01-26 17:08:40 -07:00
Felipe Leme
bd00fef41c Moar AutoFill Framework refactoring...
* Encapsulated application-level auto-fill logic on AutoFillSession.
  Currently, Activity.java directly manages the IAutoFillCallback binder
  object used to auto-fill its views, but this logic need to be
  extended so Views can use it to draw the auto-fill bar.

* Pass auto-fill id and boundaries to requests
  So AutoFillUI can display its affordance in the right places.

* Uses a new auto-fill id on View (instead of reusing accessibility's).
  That allows moving the logic on whether a new request should be made or
  the existing UI moved to the service side.

* Split service methods in 2, for shell cmd and app
  And applied the right permission check on both.

* Removed CancelationSignal from onSaveRequest()
  Since it's not really needed.

* Etc...
  ¯\_(ツ)_/¯

BUG: 34637800
BUG: 31001899
Test: CtsAutoFillServiceTestCases passes
Test: manual verification

Change-Id: Ibd0cb2cfff6d0f6bb6b697a423ed5e89df687b82
2017-01-26 15:39:59 -08:00
Amith Yamasani
dacf5e522e Merge "Add NPE check before stopping profiler" 2017-01-26 23:04:07 +00:00
Amith Yamasani
b1684439b5 Add NPE check before stopping profiler
During crash scenarios, stopProfiling() could be called early.

Change-Id: I6ef78a47e3431dd7c41198ec29d40ebef3928c6a
Fixes: 34744398
Test: N/A
2017-01-26 14:58:26 -08:00
Jeremy Joslin
8077e15563 Minor javadoc cleanup.
Test: none
Change-Id: Iaf1206767a6d0dc7a045a8fd6dc2a992ca6f3f1b
2017-01-26 11:30:37 -08:00
Esteban Talavera
2f897917fd Profile owners on a user can communicate with device owners
Allow device owners and profile owners on a user
to communicate with each other, rather than restricting
it to device owners and managed profile owners as it is
at the moment

Bug: 34429083

Test:  runtest -c com.android.server.devicepolicy.DevicePolicyManagerTest    frameworks-services
Test: cts-tradefed run cts -a armeabi-v7a --module DevicePolicyManager --test com.android.cts.devicepolicy.DeviceOwnerPlusManagedProfileTest
Change-Id: I81561a9838c3ccb623354a1b718da2fc6a5af1fe
2017-01-26 18:40:59 +00:00
TreeHugger Robot
9e77aefe9c Merge "[Frameworks] Add an 'am' cmd option to enable streaming in profiling." 2017-01-26 18:08:40 +00:00