Commit Graph

32074 Commits

Author SHA1 Message Date
Adam Lesinski
e6ed04a7ec am 2dc3c739: am ff5cbab5: Merge "Ensures that CompatibilityInfo is always set in Resources" into klp-dev
* commit '2dc3c7398b2d8965f8017bc25f2e9a29c6b83c3d':
  Ensures that CompatibilityInfo is always set in Resources
2013-09-20 11:29:12 -07:00
Adam Lesinski
2dc3c7398b am ff5cbab5: Merge "Ensures that CompatibilityInfo is always set in Resources" into klp-dev
* commit 'ff5cbab50076baa06333b6ee05cc04c882a7ba13':
  Ensures that CompatibilityInfo is always set in Resources
2013-09-20 11:24:46 -07:00
Adam Lesinski
ff5cbab500 Merge "Ensures that CompatibilityInfo is always set in Resources" into klp-dev 2013-09-20 18:22:17 +00:00
Svetoslav
6e1e8b17c5 am c0e1ae01: am facc08c7: Merge "Move PdfDocument to android.graphics.pdf" into klp-dev
* commit 'c0e1ae0176b2ce23ea1b19883507cd920712289a':
  Move PdfDocument to android.graphics.pdf
2013-09-20 11:21:05 -07:00
Adam Lesinski
79a8ffe54f Ensures that CompatibilityInfo is always set in Resources
- Adds null checks when setting mCompatibilityInfo and uses default no-op
  CompatibilityInfo object instead of null
- Removes null checks when calling methods on mCompatibilityInfo since it is never
  null

bug:10204942

Change-Id: I36e88f5cdceb46b8b19fb902270ef74023a81546
2013-09-20 11:04:40 -07:00
Dianne Hackborn
9bef5b67dc resolved conflicts for merge of 20021b30 to master
Change-Id: Ie758de25a277ed0a25bf08e4cd2c57c9519bd52d
2013-09-20 10:40:34 -07:00
Craig Mautner
2c34bd6a9a am cd569b31: am e8a94224: Merge "Return tasks in correct order." into klp-dev
* commit 'cd569b31d398fe846eeee567d2816a3bb93dd493':
  Return tasks in correct order.
2013-09-20 09:58:22 -07:00
Christopher Tate
0719715586 am 654aad21: am 9c5cc571: Merge "Support for "not the home app you\'re looking for" metadata" into klp-dev
* commit '654aad21609642f7d0891962d72c0dfd4077fb94':
  Support for "not the home app you're looking for" metadata
2013-09-20 09:58:18 -07:00
Svetoslav
c0e1ae0176 am facc08c7: Merge "Move PdfDocument to android.graphics.pdf" into klp-dev
* commit 'facc08c7757cef56da6d10e78ce99ef7949700e3':
  Move PdfDocument to android.graphics.pdf
2013-09-19 18:17:05 -07:00
Svetoslav
facc08c775 Merge "Move PdfDocument to android.graphics.pdf" into klp-dev 2013-09-20 01:14:02 +00:00
Svetoslav
44634bbefc resolved conflicts for merge of db7659e0 to master
Change-Id: I6b56fabd07b18dfcb25be83834e4f248f8aa4a40
2013-09-19 17:44:13 -07:00
Svetoslav
6811f4e92c Move PdfDocument to android.graphics.pdf
1. Move PdfDocument to android.graphics.pdf.

2. Changed the PdfDocument as per API concil request.

3. Updated the documentation.

bug:10461180
bug:10552565
bug:10681585
bug:10552336

Change-Id: I08e15b34cf37bb064248c887e6f59808019cafe8
2013-09-19 17:12:47 -07:00
Dianne Hackborn
20021b300f am 70817c47: Merge "Implement issue #10691475: Kill cached processes if about to..." into klp-dev
* commit '70817c479aa05778733d9afc809c311e8030b000':
  Implement issue #10691475: Kill cached processes if about to...
2013-09-19 14:49:35 -07:00
Dianne Hackborn
3bc8f78d7a Implement issue #10691475: Kill cached processes if about to...
...be uncached and too large

When the device is in a low RAM state, when we go to pull a cached
process out to use for some background operation, we can now kill
the current process if we consider its size to be too large.

Note that the current implementation for killing processes is to
just use the same killUnneededProcessLocked() method that we already
have for other things like too many cached processes.  This is a
little wrong here, though, because in this case we are at the
point where the caller is actually looking for a process to use.
This current code is not actually removing or cleaning up the
process, so we still need to return the now killed ProcessRecord
and let things fall out from there, which typically means the caller
trying to make an IPC on it and failing and falling into its "oh
no the process died unexpectedly" path.  All code using this
*should* be able to handle this correctly, anyway, since processes
really can be killed at any time.

At some point we may to make this implementation cleaner, where it
actually tears down the process right in the call and returns a
null ProcessRecord.  That is very dangerous however (we'd need to
go through all paths into this to make sure they are going to be
okay with process state changing on them like that), and I'm not
sure it is really worthwhile.  This intention is that killing
processes like this is unusual, due to processes being too large,
and anyway as I wrote all of our incoming code paths must already
be able to handle the process being killed at this point and one
could argue this is just another way to excercise those code paths.
Really, the main negative to this is that we will often have spam
in the log with exceptions about processes dying unexpectedly.
If that is the only issue, we could just add some conditions to
quiet that up at in this case.

We don't want to compute the size of the process each time we try
to evaluate it here (it takes 10s or ms to do so), so there is now
a new field associated with the process to give us the last pss
size we computed for it while it was in the cached state.

To be able to have better cached pss data when we now need it, the
timing for computing process pss has been tuned to use a much
shorter delay for the situations when the process has first switch
into a new state.  This may result in us having a fair amount more
pss data overall, which is good, as long as it doesn't cause us to
be computing pss excessively and burning cpu.

Procstats now also has new state to keep track of the number of
times each process has been killed by this new system, along with
the min, avg, max pss of all the times it has happened.  This has
slightly changed the checkin format to include this additional data
at the end of pkgkills/prockills lines.

Other changes here:

- Fixed a problem where GPU RAM was not being seen when dumping
  the full RAM details of a process.  This was because in that
  case the system would ask the process to compute its own MemInfo,
  which it returned, but the process doesn't have permission to
  access the files containing the GPU RAM data.  So now the system
  always computes the MemInfo and hands it to the app.

- Improved broadcast delays to not apply the delay if the next receiver
  of the broadcast is going to run in the same process as the last
  one.  A situation I was seeing was an application that had two
  receivers, one of which started a service; we are better off letting
  the second receiver run while the service is running.

- Changed the alarm manager's TIME_TICK broadcast to be a foreground
  broadcast.  This really should have been anyway (it is supposed to
  go out even minute, on the minute, very accurately, for UI elements
  to update), and is even more important now that we are doing more
  things to delay background broadcasts.

- Reworked how we maintain the LRU process list.  It is now divided
  into the two parts, the top always containing the processes holding
  activities.  This better matches the semantics we want (always try
  to keep those around modulated by the LRU order we interleave with
  other cached processes), and we now know whether a process is being
  moved on the LRU list because of an activity operation so we can
  only change the order of these activity processes when user operations
  happen.  Further, this just makes that common code path a lot simpler
  and gets rid of all the old complexity that doesn't make sense any
  more.

Change-Id: I04933ec3931b96db70b2b6ac109c071698e124eb
2013-09-19 14:35:53 -07:00
Craig Mautner
cd569b31d3 am e8a94224: Merge "Return tasks in correct order." into klp-dev
* commit 'e8a9422495d6af9fc68cf4e838a4a5f19177034b':
  Return tasks in correct order.
2013-09-19 13:05:43 -07:00
Craig Mautner
e8a9422495 Merge "Return tasks in correct order." into klp-dev 2013-09-19 20:03:24 +00:00
Christopher Tate
654aad2160 am 9c5cc571: Merge "Support for "not the home app you\'re looking for" metadata" into klp-dev
* commit '9c5cc571e5abf97a816fea2b04cd1e711e83564c':
  Support for "not the home app you're looking for" metadata
2013-09-19 12:48:19 -07:00
Christopher Tate
9c5cc571e5 Merge "Support for "not the home app you're looking for" metadata" into klp-dev 2013-09-19 19:46:20 +00:00
Christopher Tate
bd413f6c05 Support for "not the home app you're looking for" metadata
* Make sure that pm.getHomeActivities() returns the activity metadata
  as well, so that the caller can trace the reference

* Add a public canonical name for that metadata key

Bug 10749961

Change-Id: Ic4d0750d61001ffe5af180398f042afa30eea1ce
2013-09-19 12:31:49 -07:00
Craig Mautner
c0fd805234 Return tasks in correct order.
Fixed ActivityManager.getRunningTasks().

Fixes bug 10705790.

Change-Id: Ia3f66e592e08a87896a1ab59f980618ec5310dfe
2013-09-19 11:20:17 -07:00
Svetoslav
db7659e0d3 am 81d4014c: Hiding a method that was never meant to be public.
* commit '81d4014c59d2c6cf23b0465e9b8c94b6bfe428e2':
  Hiding a method that was never meant to be public.
2013-09-19 10:27:59 -07:00
Svetoslav
81d4014c59 Hiding a method that was never meant to be public.
The hide javadoc annotation had a type, thus leaking the API.

bug:10552358

Change-Id: Iec4e203d0786efbe6afbd9b6995f11642935336c
2013-09-19 10:09:49 -07:00
Amith Yamasani
0125d4bd25 am 2f9fd33f: am e8c01ddb: Merge "Changes to PFD based on API review" into klp-dev
* commit '2f9fd33fd9cad3bbd8edffefa9c65cbeb7e50c94':
  Changes to PFD based on API review
2013-09-18 16:47:50 -07:00
Amith Yamasani
2f9fd33fd9 am e8c01ddb: Merge "Changes to PFD based on API review" into klp-dev
* commit 'e8c01ddbe748490463f7f516df9b1b4784228913':
  Changes to PFD based on API review
2013-09-18 16:45:32 -07:00
Amith Yamasani
e8c01ddbe7 Merge "Changes to PFD based on API review" into klp-dev 2013-09-18 23:43:11 +00:00
Alan Viverette
7f67d7206a am 8ac0d137: am 564c45b9: Merge "Fix number picker vertical scroll computations" into klp-dev
* commit '8ac0d137ba11958312e25225d8d0776aad71b022':
  Fix number picker vertical scroll computations
2013-09-18 16:42:15 -07:00
Alan Viverette
8ac0d137ba am 564c45b9: Merge "Fix number picker vertical scroll computations" into klp-dev
* commit '564c45b976b56bc33f18271e1c813a0bd91b2eb4':
  Fix number picker vertical scroll computations
2013-09-18 16:38:55 -07:00
Amith Yamasani
b433bb8c96 Changes to PFD based on API review
Removed boolean param to ask for exception on detached fd. Use a
subclass of IOException instead.

Bug: 10461576
Change-Id: If7db16120297edcdb7d5d5905ed453003be0e38e
2013-09-18 16:35:05 -07:00
Alan Viverette
564c45b976 Merge "Fix number picker vertical scroll computations" into klp-dev 2013-09-18 23:35:02 +00:00
Svetoslav
932916b3e7 am 6d0db04b: am 7b3990ec: Merge "Update the print dialog." into klp-dev
* commit '6d0db04bed79f371b537feae3efa9b5e6fe8876c':
  Update the print dialog.
2013-09-18 14:27:03 -07:00
Raph Levien
0a675ae85a am 954f0d7b: am ba1abbba: Merge "Revert "Revert "Take the input device into account for meta state""" into klp-dev
* commit '954f0d7b775b67c3ceeb7d3f646479fbc420fbd7':
  Revert "Revert "Take the input device into account for meta state""
2013-09-18 14:26:45 -07:00
Kenny Root
b5a14f0fc9 resolved conflicts for merge of 1995a7de to master
Change-Id: I9915ae06d460696b24cbee935738267911baa580
2013-09-18 14:23:58 -07:00
Svetoslav
6d0db04bed am 7b3990ec: Merge "Update the print dialog." into klp-dev
* commit '7b3990ec81fc218f655d44624758e15ce378968e':
  Update the print dialog.
2013-09-18 14:12:58 -07:00
Svetoslav
7b3990ec81 Merge "Update the print dialog." into klp-dev 2013-09-18 21:08:49 +00:00
Raph Levien
954f0d7b77 am ba1abbba: Merge "Revert "Revert "Take the input device into account for meta state""" into klp-dev
* commit 'ba1abbba1f140f4be5956ade8ffd4ef4b3f9ffe0':
  Revert "Revert "Take the input device into account for meta state""
2013-09-18 13:42:41 -07:00
Raph Levien
ba1abbba1f Merge "Revert "Revert "Take the input device into account for meta state""" into klp-dev 2013-09-18 20:40:26 +00:00
Dianne Hackborn
1995a7de5b am b9466db4: Merge "Finish issue #10779747: Calendar Storage crash observed..." into klp-dev
* commit 'b9466db4a56564101a26865962dda87aaeab56ff':
  Finish issue #10779747: Calendar Storage crash observed...
2013-09-18 13:37:02 -07:00
Dianne Hackborn
b9466db4a5 Merge "Finish issue #10779747: Calendar Storage crash observed..." into klp-dev 2013-09-18 20:34:11 +00:00
Jonathan Dixon
cfdcdf9f3f am 515134e8: am c7969dea: Merge "Fix obsolete API reference" into klp-dev
* commit '515134e88c0c1cdfb06a1ec22946554d2d98c8d2':
  Fix obsolete API reference
2013-09-18 13:13:03 -07:00
Jonathan Dixon
515134e88c am c7969dea: Merge "Fix obsolete API reference" into klp-dev
* commit 'c7969dea24f2e362f69fb2b912c8a0385f5dc617':
  Fix obsolete API reference
2013-09-18 13:10:15 -07:00
Jonathan Dixon
c7969dea24 Merge "Fix obsolete API reference" into klp-dev 2013-09-18 20:06:20 +00:00
Raph Levien
14f10e5d5f Revert "Revert "Take the input device into account for meta state""
This reverts commit 3954fd9a05, which
is equivalent to re-applying 8a1597b396.

The change ("Take the input device into account for meta state") was
valid but caused CTS test failures because the test was wrong. The
test injected a key event with the meta state missing. This faulty
test was masked by the old toggle behavior.
2013-09-18 13:01:11 -07:00
Jonathan Dixon
df3859ebeb Fix obsolete API reference
Bug 10361803

exportToPdf use-case not supported in K so removing that dangling
reference from the javadoc

Change-Id: Ia0fe3aa9ed5150639d1f72341c89568a0a7e1c7d
2013-09-18 12:51:47 -07:00
Raph Levien
c4d7562a93 am 21b0c88b: am c540f8e9: Merge "Revert "Take the input device into account for meta state"" into klp-dev
* commit '21b0c88b3c290141f9a7593bb249ab117af48b91':
  Revert "Take the input device into account for meta state"
2013-09-18 12:49:33 -07:00
Raph Levien
21b0c88b3c am c540f8e9: Merge "Revert "Take the input device into account for meta state"" into klp-dev
* commit 'c540f8e9d704414a06f7a5b4ade1c713042f8c38':
  Revert "Take the input device into account for meta state"
2013-09-18 12:46:57 -07:00
Raph Levien
c540f8e9d7 Merge "Revert "Take the input device into account for meta state"" into klp-dev 2013-09-18 19:44:16 +00:00
Svetoslav
013b816ac7 Update the print dialog.
1. The print dialog was resizable and as a result when printers
   come and go its size changes which looks bad. The dialog is
   now trying to be maximally large limited by a max size or the
   screen - whichever is smaller. This required moving from
   GridLayout to several LinearLayouts since the former does not
   support distribution of empty space evently between the items
   in a row. Also we want all items in a column of inputs to be
   of equal size (the spinners specifically).

2. Added labeledBy attribute to associate a view with another one
   that serves as its label for accessibility purposes. We have
   lebelFor attribute but it is not useful in most layout files
   since it has to refer the auto-generated id of a view which
   usually appears later in the layout file, thus generating a
   compilation error. This was needed for the accessibility support
   of the print dialog.

bug:10631660

2. Disabling the spinners or the print button did not produce
   visual feedback leading to user frustration.

bug:10741907

Change-Id: I0c12eddabc4035bc7becd1b86c1f1b8fdcf4289c
2013-09-18 12:31:26 -07:00
Jonathan Dixon
322fe808e3 am b7bdf38b: am 01fc0884: Merge "Update APIs for the Chromium WebView" into klp-dev
* commit 'b7bdf38bf1d202c844e667f3074bc43f298f11f9':
  Update APIs for the Chromium WebView
2013-09-18 12:22:20 -07:00
Jonathan Dixon
b7bdf38bf1 am 01fc0884: Merge "Update APIs for the Chromium WebView" into klp-dev
* commit '01fc088462d05478bcdf416fb02532d53e85dd6a':
  Update APIs for the Chromium WebView
2013-09-18 12:17:58 -07:00
Jonathan Dixon
01fc088462 Merge "Update APIs for the Chromium WebView" into klp-dev 2013-09-18 19:14:09 +00:00