1555 Commits

Author SHA1 Message Date
Wale Ogunwale
079a0044a3 API for moving top activity in a stack to pinned stack.
* AMS.moveTopStackActivityToPinnedStack can be used to move the top
activity in a stack to the pinned stack and also specify the bounds
the pinned stack should be sized to.
* 'am stack move-top-activity-to-pinned-stack' command for testing
AMS.moveTopStackActivityToPinnedStack API

Bug: 25006507
Change-Id: I8392b4c39d8542153e691be7a627b7f35fd44884
2015-10-26 12:07:00 -07:00
Elliott Hughes
46a114dfcf Merge "Fix lseek argument order." am: 12dccb8a24 am: 9bbe41642a
am: 2876b1f169

* commit '2876b1f169e5342e46b27f3f94a8816837c9f61a':
  Fix lseek argument order.
2015-10-20 23:51:55 +00:00
Elliott Hughes
9bbe41642a Merge "Fix lseek argument order."
am: 12dccb8a24

* commit '12dccb8a2450152102b32bf4882200f6b08a5a5a':
  Fix lseek argument order.
2015-10-20 20:35:44 +00:00
Elliott Hughes
70bef1c4bd Fix lseek argument order.
Change-Id: Ibc2f98e4c26d0ac6ac7b4a73775c5213c4df4518
2015-10-20 13:23:18 -07:00
Pablo Ceballos
63afb86381 Merge "Remove GLTrace support" 2015-10-19 17:55:59 +00:00
Brian Carlstrom
80435a7fcd am bd5b6252: am b9a28ae1: am f916524f: Merge "Add support for --user to "pm path" for work profile use"
* commit 'bd5b6252a5dd068c2db30fbbd16e87a656047197':
  Add support for --user to "pm path" for work profile use
2015-10-15 16:16:07 +00:00
Brian Carlstrom
b9a28ae199 am f916524f: Merge "Add support for --user to "pm path" for work profile use"
* commit 'f916524f44c9955e7c747e5319d17c46a61a3c4c':
  Add support for --user to "pm path" for work profile use
2015-10-15 16:02:57 +00:00
Brian Carlstrom
f916524f44 Merge "Add support for --user to "pm path" for work profile use" 2015-10-15 15:55:45 +00:00
Wale Ogunwale
5247523c90 Merge "Don't set incorrect stack bounds when rotating screen in docked mode" 2015-10-13 01:58:05 +00:00
Wale Ogunwale
ffc11bb712 Don't set incorrect stack bounds when rotating screen in docked mode
Both window manager and activity manager could decide what the bounds
of other stacks should be when the docked stack exist which can get
out of sync. Now window manager does the bounds calculation and
activity manager asks window manager what the bounds should be when
it needs to resize the stack.

Bug: 24738105
Change-Id: I97356f008b676d2f58a8b54fdb08735ab51394af
2015-10-12 18:56:28 -07:00
Adam Lesinski
f5e18154b0 am b8f8ca51: am 651cb804: am fe1934e4: Merge "RRO: idmap: allow flock(2) to block"
* commit 'b8f8ca5139e3268c7447565940b63a543ebe9ed5':
  RRO: idmap: allow flock(2) to block
2015-10-13 01:24:48 +00:00
Adam Lesinski
81892b095b am 41bf75c6: am 287cd2d1: am bac309ca: Merge "RRO: idmap: fix sorting of overlays.list"
* commit '41bf75c606fa19b473bc87145f766757525ae96c':
  RRO: idmap: fix sorting of overlays.list
2015-10-13 01:24:38 +00:00
Adam Lesinski
45f704a4d0 am 89eaa06a: am 6382a950: am 2327239d: Merge "Handle \'root\' pseudo-package in the appops command"
* commit '89eaa06a10ed399ae9919de2795f76c2af932adc':
  Handle 'root' pseudo-package in the appops command
2015-10-13 01:24:29 +00:00
Adam Lesinski
4ffea4e4da am d0c806b1: am 6029dfa8: am 7caa8f14: Merge "Make \'idmap --scan\' accept more than one input directory"
* commit 'd0c806b10c8e45dcfa950adc36742b15edababea':
  Make 'idmap --scan' accept more than one input directory
2015-10-13 01:24:16 +00:00
Adam Lesinski
651cb804b1 am fe1934e4: Merge "RRO: idmap: allow flock(2) to block"
* commit 'fe1934e470681ff7ec5b8ec0609ae9fe24bd7282':
  RRO: idmap: allow flock(2) to block
2015-10-12 19:34:43 +00:00
Adam Lesinski
287cd2d1e4 am bac309ca: Merge "RRO: idmap: fix sorting of overlays.list"
* commit 'bac309ca8f4ecd1a835aa36f4be2a1fa45577eab':
  RRO: idmap: fix sorting of overlays.list
2015-10-12 19:34:37 +00:00
Adam Lesinski
6382a950cd am 2327239d: Merge "Handle \'root\' pseudo-package in the appops command"
* commit '2327239d65525d8ba2bdbedd6e59809fef447a12':
  Handle 'root' pseudo-package in the appops command
2015-10-12 19:34:28 +00:00
Adam Lesinski
fe1934e470 Merge "RRO: idmap: allow flock(2) to block" 2015-10-12 19:30:23 +00:00
Adam Lesinski
bac309ca8f Merge "RRO: idmap: fix sorting of overlays.list" 2015-10-12 19:29:39 +00:00
Adam Lesinski
2327239d65 Merge "Handle 'root' pseudo-package in the appops command" 2015-10-12 19:29:14 +00:00
Adam Lesinski
6029dfa81a am 7caa8f14: Merge "Make \'idmap --scan\' accept more than one input directory"
* commit '7caa8f14a78d279e0392089dca2f54f27e7f5d15':
  Make 'idmap --scan' accept more than one input directory
2015-10-12 18:59:03 +00:00
Snild Dolkow
3875bf6c04 Handle 'root' pseudo-package in the appops command
The AppOpsService handles the 'root' pseudo-package as any other; it
gets no automatic allowances. This is reasonable, but it blocked me from
accessing the mms-sms provider through the 'content' command, even in a
root shell.

So I tried to change the rules:

$ adb root
$ adb shell appops set root WRITE_SMS allow
Error: No UID for root in user 0

This error occurs in the appops command because there isn't really a
package called root, so the UID lookup via PackageManager fails.

But we know that root is UID 0, so we can just skip the lookup.
(Also, AppOpsService handles the other way around in getOpsLocked method.)

Change-Id: Ie0cad67efa438a74a4d9921d29933610cfb13974
2015-10-07 19:58:17 +02:00
Mårten Kongstad
7197d91eb7 RRO: idmap: fix sorting of overlays.list
Multiple overlay packages with targetPackage="android" are loaded in the
wrong order due to the incorrect order they are listed in overlays.list.
This will cause runtime resource overlay to fail when multiple overlay
packages target the same resources in framework-res.apk.

Correct the order in which overlays are loaded by changing the sorting
of overlays.list.

Background: commit f90f2f8d changed the order in which overlay packages
should be added to ResTables. The expected order is now in ascending
priority. This must be reflected in overlays.list.

Change-Id: I249984c0e34b6009e7280ce2777750c76ab16e37
2015-10-07 19:51:50 +02:00
Mårten Kongstad
83ab0d7c18 Make 'idmap --scan' accept more than one input directory
The 'idmap --scan' command was limited to only scan a single directory
for overlay packages. Update idmap to support any number of directories.

Change-Id: I851f5720a3c1d844235911a0833670652a20a3c8
2015-10-07 19:45:09 +02:00
Mårten Kongstad
df1a5b22cd RRO: idmap: allow flock(2) to block
During creation of an idmap an advisory lock is applied on the
output file using flock(2). This commit removes the LOCK_NB flag
from the call to flock(2).

The reason for this is that if the function were to return
EWOULDBLOCK, the entire idmap operation would be aborted leading
to the device booting without the correct overlay packages applied.

Change-Id: Iad319779976e950d4354e4f60b30439f6f208b77
2015-10-07 19:02:09 +02:00
Pablo Ceballos
a4d4e82927 Remove GLTrace support
GLTrace is defunct, it does not support newer GL features, breaks
security requirements, and has no supported tooling now that Eclipse
is at end of life.

Bug 22329852

Change-Id: I64c58464f8c2c7ae6125f5d5c7884e3fd34d68ea
2015-10-06 15:18:40 -07:00
Makoto Onuki
a52562ca9a setDeviceOwner() now requires a full component name.
Bug 20149907

Change-Id: I24e66159d1d966925aa3a494b1e2839b07cdafa2
2015-10-05 16:05:15 -07:00
Makoto Onuki
3e832afec3 Merge "Fix "pm list permissions GROUP"" 2015-10-05 16:03:00 +00:00
Makoto Onuki
008b932d95 Fix "pm list permissions GROUP"
The command wasn't parsing a group name correctly.

Change-Id: I966e56e2f7b3eab2531be6bec8f744735b865910
2015-10-02 16:51:56 -07:00
Fyodor Kupolov
0df68cd13b Do now allow current user to be removed
It was possible to remove a foreground user using pm remove-user command.
The system ends up in the inconsistent state, because switch does not happen
and the removed user stays in the foreground, but its state is removed.

Also added am get-current-user command.

Change-Id: Ida2dce8f99bac55e106cdd44c93e96cc9142d7fb
2015-10-02 12:19:39 -07:00
Fyodor Kupolov
02cb6e773b Added --restricted option for create-user command
Also moved restricted profile create/setup logic from Settings to
UMS.createRestrictedProfile.

Bug: 24212155
Bug: 24303609
Change-Id: I0346a3368de53f4bb4b6e054349f19adac959d7f
2015-09-28 10:01:54 -07:00
Bart Sears
9249a90977 Revert "Added --restricted option for create-user command"
This reverts commit 737b216b5c28f7d7162f219136d4e8a9eb1a486b.

Change-Id: I4c43967933bb2e46cdb8ad6e643d7037d722cab2
2015-09-26 01:58:59 +00:00
Brian Carlstrom
f83612b295 Add support for --user to "pm path" for work profile use
Change-Id: Ic8bb923e15a40f32cc7daa6a344250abfc81e423
2015-09-25 13:08:35 -07:00
Fyodor Kupolov
737b216b5c Added --restricted option for create-user command
Also moved restricted profile create/setup logic from Settings to
UMS.createRestrictedProfile.

Bug: 24212155
Bug: 24303609
Change-Id: I5f0d48bcbd3c0b51927926b874fd057c15ac5219
2015-09-25 11:22:13 -07:00
Wale Ogunwale
83301a933f Added am command to suppress config. changes during task resize.
This command is useful for testing during development, but at some
point we will decide if allowing configuration changes during resizing
is okay or merge in http://ag/759766 to suppress configuration changes
during resizing and deliver the new config. to the app.

This functionality will be reverted once we decide.

Bug: 24380097
Change-Id: I223c08bc939e564a78e70994b599770be9d4730d
2015-09-24 15:54:08 -07:00
Chong Zhang
87b21722c2 Change resizeTask's parameter resizedByUser to constants
to indicate who initiated the resize, or if the resize should be forced.

Change-Id: Ic7021f76bec677027cbf27deeb63f92ea911a75c
2015-09-22 00:46:02 +00:00
Guang Zhu
51e7edc223 am 4f3a2d47: am 8bc9238f: am 9e4a4606: am fe74fb95: extend svc command to control NFC state
* commit '4f3a2d47a1b507657d7a27c193aaf2fd93c78332':
  extend svc command to control NFC state
2015-09-15 22:29:56 +00:00
Guang Zhu
4f3a2d47a1 am 8bc9238f: am 9e4a4606: am fe74fb95: extend svc command to control NFC state
* commit '8bc9238f1438c1c9359b3c8959399c0168dbfc74':
  extend svc command to control NFC state
2015-09-15 21:38:05 +00:00
Guang Zhu
fe74fb95b9 extend svc command to control NFC state
Change-Id: I599e4000fa17384089410e63b3150f25aa9458f7
2015-09-15 13:43:22 -07:00
Filip Gruszczynski
a59ac9cd64 Preserve window during resize triggered relaunches.
This changes application code behavior when the activity relaunches due
to configuration change. It only applies to scenarios, where the
configuration change was triggered by a user generated resize of an
activity (i.e. user drags a corner of an activity and thus changes its
size).

Preserving a window means that we will keep the decor view and non
client decor view around, but remove all children views when the
activity gets destroyed. When the activity gets created again, it will
attach its new content to the preserved view hierarchy. Mind, we
actually recreate application side Window object, since some of its
features might changed, but we retain its elevation (to not trigger
relayout with new layout params).

Preserving the window also means that we don't call the window manager
service to remove and later add the window. Instead, we continue using a
single window state throughout the resize operation.

Change-Id: Ie3d2878ed09c99ff343044bfe7a29a0ba07a265e
2015-09-14 15:59:32 -07:00
Makoto Onuki
58b684f1cd [split system] Tentatively support running DO on meat user
- setDeviceOwner() now takes a user ID.  (We can infer it from Binder, but
we still need it for the dpm command.)

- Change broadcast target UID for DO to the DO user

- Start the DO user on boot complete.
TODO Investigate whether this is actually the good timing.

TODO Prevent the DO user from being killed

Bug 23827706

Change-Id: I227dbd444f1f4e94d98c317489d151554fe79d91
2015-09-08 11:24:58 -07:00
Xiaohui Chen
cc791bc47c More cleanup USER_OWNER
Bug: 19913735
Change-Id: I7fe1bb2a66231b7d1ae0670dff5e2ec736b2e541
2015-08-27 18:05:21 +00:00
Chris Tate
dcaf0eccb2 am 748dd873: am 8d662a07: am e49dcfed: am 9b7a4ac5: am e62421f1: Merge "Teach Pm about the "always ask" link-handling state" into mnc-dev
* commit '748dd8736fa15f426a5accb265141a6046aa2636':
  Teach Pm about the "always ask" link-handling state
2015-08-26 00:47:50 +00:00
Chris Tate
748dd8736f am 8d662a07: am e49dcfed: am 9b7a4ac5: am e62421f1: Merge "Teach Pm about the "always ask" link-handling state" into mnc-dev
* commit '8d662a074296923d417f833e9c12b2b0bd50cfa3':
  Teach Pm about the "always ask" link-handling state
2015-08-26 00:40:19 +00:00
Chris Tate
9b7a4ac584 am e62421f1: Merge "Teach Pm about the "always ask" link-handling state" into mnc-dev
* commit 'e62421f1fbc1ea44e7737989e134fdf9fc1ec4cc':
  Teach Pm about the "always ask" link-handling state
2015-08-26 00:20:50 +00:00
Chris Tate
555f91db7c am e62421f1: Merge "Teach Pm about the "always ask" link-handling state" into mnc-dev
* commit 'e62421f1fbc1ea44e7737989e134fdf9fc1ec4cc':
  Teach Pm about the "always ask" link-handling state
2015-08-26 00:20:03 +00:00
Christopher Tate
47dd08d7fb Teach Pm about the "always ask" link-handling state
Bug 23511867

Change-Id: I74b3c8222a7d22541a96b698edd1a175d378e48f
2015-08-25 12:39:04 -07:00
Xiaohui Chen
2a5c3e59c8 pm: translate incoming user id for installation
Currently the pm install commands will not take virtual user id like
-2.  Adding this feature will make it easier to install packages in a
multi-user environment.

Bug: 19913735
Change-Id: I68b13cf8f2290158f0f4ec5c0966853719c2e80f
2015-08-24 11:00:14 -07:00
Xiaohui Chen
bd0e03bb76 More USER_OWNER cleanup.
Bug: 19913735
Change-Id: I408a92d9dbab2a096407efccb91e2a8bdc22714d
2015-08-24 16:42:37 +00:00
Tom Cherry
bbb74906be am fe0fcf5c: am b9ac485a: am 49948146: Merge "bundle init.rc contents with its service"
* commit 'fe0fcf5cad75c6ba717a3d0a4ddb7c6bc656135d':
  bundle init.rc contents with its service
2015-08-21 18:32:07 +00:00