Commit Graph

5344 Commits

Author SHA1 Message Date
Chris Wren
75313c4ebb Merge "update metrics enums" 2015-10-19 14:17:44 +00:00
Chris Wren
f885276e6f update metrics enums
Change-Id: I5c4b20dc514889493e3049b4242876633ebebcde
2015-10-16 17:41:13 -04:00
Adrian Roos
5419280fb3 am 2de89ae8: am 3c439c72: am 85fae34e: am 70ea8578: Merge "Fix wrongly laid out navigation color view" into mnc-dr-dev
* commit '2de89ae843a0a6b492eaa55f96a641df16b718a8':
  Fix wrongly laid out navigation color view
2015-10-16 21:19:03 +00:00
Wale Ogunwale
645e8a9ae8 Merge "Added support for resizing background color for an app window" 2015-10-16 21:14:06 +00:00
Adrian Roos
2de89ae843 am 3c439c72: am 85fae34e: am 70ea8578: Merge "Fix wrongly laid out navigation color view" into mnc-dr-dev
* commit '3c439c720d460266358c10d8d2eea9ef9e79beb0':
  Fix wrongly laid out navigation color view
2015-10-16 21:12:06 +00:00
Adrian Roos
85fae34e81 am 70ea8578: Merge "Fix wrongly laid out navigation color view" into mnc-dr-dev
* commit '70ea857859b78a708fb99ac708ead7bdaddf79a7':
  Fix wrongly laid out navigation color view
2015-10-16 20:49:59 +00:00
Adrian Roos
70ea857859 Merge "Fix wrongly laid out navigation color view" into mnc-dr-dev 2015-10-16 20:43:32 +00:00
Wale Ogunwale
f3a62fbc58 Added support for resizing background color for an app window
R.styleable.Window_windowResizingBackground allows an activity to
specify the background drawable that should be used when it is being
resized in multi-window mode. If unset, the system will try to use
R.styleable.Window_windowBackground if set, then
R.styleable.Window_windowBackgroundFallback if set. Otherwise, the
system default resizing background color set by
R.integer.config_windowResizingBackgroundColorARGB.

Also, use decor title color as caption background color when resizing
instead of black.

Bug: 24534744
Change-Id: I83313865b4044b976ebc78d598e14e17e0f37212
2015-10-16 12:54:31 -07:00
Adam Powell
8ebd66ca24 am 4c0011e9: am 824347dd: am d08f339b: am 749334bf: Merge "Fix ChooserTarget app scoring" into mnc-dr-dev
* commit '4c0011e98212cf2b2a9e0aa2bab32c069de3b253':
  Fix ChooserTarget app scoring
2015-10-16 18:32:13 +00:00
Adam Powell
4c0011e982 am 824347dd: am d08f339b: am 749334bf: Merge "Fix ChooserTarget app scoring" into mnc-dr-dev
* commit '824347dd8afc3b8b40e28e4b5d0743b56e341b98':
  Fix ChooserTarget app scoring
2015-10-16 18:27:05 +00:00
Adam Powell
d08f339bcc am 749334bf: Merge "Fix ChooserTarget app scoring" into mnc-dr-dev
* commit '749334bffbc92aeaef27c274a1586fa7365cbfdc':
  Fix ChooserTarget app scoring
2015-10-16 18:13:19 +00:00
Adam Powell
77a533f5b2 Fix ChooserTarget app scoring
An initial sorting step before applying modifiers to the ChooserTarget
scores provided by apps was backwards, causing subsequent target
scores to be heavily penalized. Targets are then heavily influenced by
the lowest score in the set relative to the targets from other apps.

Bug 25013559

Change-Id: I39d5d7c601712fc6a19e694d5846d2c8d17a214f
2015-10-16 10:58:08 -07:00
Abodunrinwa Toki
6a82ccbce9 am 85978d7c: am a3234f01: am 9c76f61d: Merge "DO NOT MERGE: Reduce delay of floating toolbar appearance." into mnc-dr-dev
* commit '85978d7c36e94f107bd72166bc18f893b4817cf9':
  DO NOT MERGE: Reduce delay of floating toolbar appearance.
2015-10-16 16:56:38 +00:00
Abodunrinwa Toki
a3234f0192 am 9c76f61d: Merge "DO NOT MERGE: Reduce delay of floating toolbar appearance." into mnc-dr-dev
* commit '9c76f61dea69e21eba3b89adbc2a00bcb522584e':
  DO NOT MERGE: Reduce delay of floating toolbar appearance.
2015-10-16 16:41:26 +00:00
Abodunrinwa Toki
a6200068af DO NOT MERGE: Reduce delay of floating toolbar appearance.
Bug: 21956394
Change-Id: I3db39e84afd3474b5bb53522c5a4c738ec1511bf
2015-10-16 16:01:00 +01:00
Adrian Roos
fc7476da7a Fix wrongly laid out navigation color view
The SystemUI visibility listener in DecorView
gets called between the measure and layout passes
and is therefore not allowed to change layout parameters.

This change makes sure that changes to the color view
layout parameters are applied eagerly when the insets
change instead of waiting for the views to become visible.

Bug: 24614374

Change-Id: If9df18f582163d0869c28a852c36697b1ce50621
2015-10-15 15:39:46 -07:00
Luis Hector Chavez
5dd239a1f8 Make ZygoteInit not require CAP_BLOCK_SUSPEND
We are dropping CAP_BLOCK_SUSPEND since that prevents correct suspension in
Chrome OS.  This change makes it so that it only requests that capability if it
is not running inside a container.

TEST=Android boots correctly
BUG:24952794

(cherry picked from commit 5e38447a9bf81bb7d58d33c71498495e1e0f575f)
(cherry picked from commit dc3943951ee475ef09cc7a4825368f9b707e1344)

Change-Id: If39357f22955442d5532d1408ce74360384521bb
2015-10-15 17:03:59 +00:00
Adam Powell
b60d985561 am 2271385a: am bd4d81b0: am b248077a: am 2eac005b: Merge "Fix bugs introduced in ChooserActivity" into mnc-dr-dev
* commit '2271385ad8845d86af2a3aba6b03ec3113e9b9be':
  Fix bugs introduced in ChooserActivity
2015-10-15 00:13:47 +00:00
Adam Powell
2271385ad8 am bd4d81b0: am b248077a: am 2eac005b: Merge "Fix bugs introduced in ChooserActivity" into mnc-dr-dev
* commit 'bd4d81b08cc5d961da294c683a73c6c13e3eb931':
  Fix bugs introduced in ChooserActivity
2015-10-15 00:08:14 +00:00
Adam Powell
b248077a8a am 2eac005b: Merge "Fix bugs introduced in ChooserActivity" into mnc-dr-dev
* commit '2eac005bbfc94a774c0a3f870fd393a3e7389f8c':
  Fix bugs introduced in ChooserActivity
2015-10-14 23:52:14 +00:00
Adam Powell
4eb9871ead Fix bugs introduced in ChooserActivity
* Wait to start animations until all state has been initialized, as
  the process of starting an Animator will set initial values,
  triggering other events relying on the configured state.

* Correctly track underlying item indexes for columns.

* Do not over-extend the ResolverDrawerLayout when multiple rows
  animate in.

Bug 24926885
Bug 24928706

Change-Id: I4772e1a0ba79b17b5dc19c778f3ef0cb5200c533
2015-10-14 13:10:18 -07:00
Filip Gruszczynski
2dfcf5ce2e Keep freeform window surface translucent during resize.
Freeform window surfaces are translucent because most of the time they
have shadows. During a resize we stop displaying the shadow, which
might change the surface opacity from translucent to opaque. This change
only happens if the activity gets recreated during the resize, as this
triggers recalculation of the necessary opacity. If configuration change
happens the relayout will now contain new, opaque pixel format and cause
the recreation. The second blink will happen after we finish resizing,
as the surface needs to become translucent again.

Bug: 24668341
Change-Id: I450323276c49f176f0f6dfb3b21a5f6d742a8418
2015-10-14 09:22:42 -07:00
Adam Powell
d86a7f4cf7 am 1901a9e1: am 40ce70c9: am 11af1878: Merge "Add animation and positional stability to intent chooser UI" into mnc-dr-dev
* commit '1901a9e199eee9102c829413528029dc25855987':
  Add animation and positional stability to intent chooser UI
2015-10-13 00:20:51 +00:00
Adam Powell
40ce70c9c0 am 11af1878: Merge "Add animation and positional stability to intent chooser UI" into mnc-dr-dev
* commit '11af18783d32f8646428500a0ff3a2a57a77bf95':
  Add animation and positional stability to intent chooser UI
2015-10-12 23:33:22 +00:00
Adam Powell
11af18783d Merge "Add animation and positional stability to intent chooser UI" into mnc-dr-dev 2015-10-12 23:28:36 +00:00
Chong Zhang
8dbd9ad682 Fix missing frame or wrong frame position when resize starts
When multi-thread renderer is used, delay the report to draw to the
first doFrame in ResizeFrameThread. Otherwise we could unfreeze the
window before the frame is drawn.

Also when content draw bounds is updated for the first frame, let
content draw before ResizeFrameThread so that the bounds get applied.

bug: 24715185

Change-Id: I5485dc0be3eae24c555bcc31ee8f71523b68ca8d
2015-10-12 11:01:14 -07:00
Wale Ogunwale
d16ebb0d09 Allow apps in home workspace to have non-client-decor.
Currently required for apps like recents to resize correctly
with the 2-render thread approach. Eventually we will want to
separate the functionality from the non-client-decor.

Bug: 24742523
Bug: 24810450
Change-Id: Id241bf8fe47dd8c4ec570c90149c859c45aa6285
2015-10-09 13:25:14 -07:00
Wale Ogunwale
013f84ab79 Merge "Synchronize critical sections in NonClientDecorView.ResizeFrameThread" 2015-10-08 23:33:10 +00:00
Alan Viverette
1aba36d721 Merge "Revert "Reduce CascadingMenuPopup's reliance on internal ListView state"" 2015-10-08 19:54:49 +00:00
Alan Viverette
2ac975deb3 Revert "Reduce CascadingMenuPopup's reliance on internal ListView state"
Introduced some regressions. Reverting until we can do better testing.

This reverts commit 8375d63998.

Change-Id: I9b15d63e52c814ef8985b86f8a50359e39355d39
2015-10-08 19:54:16 +00:00
Wale Ogunwale
25cd08ca15 Synchronize critical sections in NonClientDecorView.ResizeFrameThread
Prevents multiple-threads from accessing/changing member variables at
the same time that can lead to the app crashing.

Also, setName on ResizeFrameThread so we can easily find it in systrace.

Bug: 24745288
Change-Id: Ic2fc7d661db5360c13314197c40e8b2315d2b7e5
2015-10-08 12:44:53 -07:00
Filip Gruszczynski
c10bcedc3a Fix leak of decor view children.
When activity doesn't have a non client decor view but we preserve its
windows, we need to remove the children directly from the decor view
instead.

Bug: 24750271
Change-Id: I50e83ef61deba92e668ee165c4a297547a56071f
2015-10-08 12:24:02 -07:00
Skuhne
980ee47ffe Resolving incorrect rendering of content while resize
The staged content bounds need to be set by the content renderer
and not by the resize thread.

Bug: 24671393
Change-Id: I8f84ec01a4ac6c1e783cc6208ca77ca6c01ba838
2015-10-06 13:52:17 -07:00
Chong Zhang
a42521ca0a Merge "Make window callbacks non static member of ViewRootImpl" 2015-10-06 18:56:13 +00:00
Alan Viverette
266cdd4839 Merge "Reduce CascadingMenuPopup's reliance on internal ListView state" 2015-10-06 18:43:24 +00:00
Adam Powell
acaaee06f6 Merge "Add animation and positional stability to intent chooser UI" 2015-10-06 18:14:02 +00:00
Chong Zhang
dcee1dea6b Make window callbacks non static member of ViewRootImpl
Move add/removeWindowCallbacks to onAttachedToWindow/onDetachedFromWindow.

There might be more than one windows in an app process, the window
callbacks need to be per window, not global.

bug: 24679461
Change-Id: I216ff27b2a41ecfe7399a8161df362bebc0ac96a
2015-10-06 10:29:55 -07:00
Alan Viverette
8375d63998 Reduce CascadingMenuPopup's reliance on internal ListView state
Bundles cascading menu information and stores it in a stack representing
the hierarchy of added menus.

Bug: 23970448
Change-Id: Icc0a96ea2dd4320fd4dae9626435ed82a6165480
2015-10-06 10:40:25 -04:00
Chet Haase
4164e6a8da Merge "Enable activity rendering during window animations" 2015-10-05 22:27:02 +00:00
Chet Haase
9c45041105 Enable activity rendering during window animations
A change was made back in ICS that prevents the view hierarchy from rendering
during window animations. Specifically, it allows the hierarchy to render once (to draw
the results of its first layout), but further drawing is suppressed at the
ViewRoot/performTraversals level until the window animation is complete.

This change was introduced to avoid jank problems that were resulting from
thrashing the GPU by issuing drawing commands from multiple processes simultaneously,
and limited the number of rendering processes to mainly the system server (and
possibly the System UI), which allowed window animations to be much smoother.

This fix contributed to another source of jank, however, in which applications
which attempt to animate when they first appear will not render any frames of
animations until the window animation is done, resulting is a snapping to the resulting
state once the window animations are complete.

Meanwhile, hardware has gotten faster and GPUs have gotten better, and it is time to
revisit this logic. This change disables the earlier fix and allows view hierarchies
to draw normally, regardless of whether window animations are taking place.

Issue #22232939 Remove flag that prevents drawing during window animations

Change-Id: I4c960180771ff09a7088abd77b437586e835a991
2015-10-05 14:58:17 -07:00
Filip Gruszczynski
14418daa09 Fix recents crashing during docked stack resize.
Whether acitvity window should be preserved during the relaunch is
controlled by the activity manager and the existence of
non-client-decor should not affect it. For example, docked activities
will not have non-client-decor, but we would like to preserve them
anyway.

Bug: 24573657
Change-Id: I5d4852c3b7c26ac3ec1bbc105639f75b67d1d3ad
2015-10-05 10:56:49 -07:00
Skuhne
cc075c76ff Possible resize flickering on config change
It is possible that while a config change is going on, the
view hiererchy got created but not layouted. In that case
the reported size of the main window would be 0,0. In this
event we need to use the cached window sizes from the past
render.

Bug: 24595899
Change-Id: Ia41f7ae0999e4f2bda364506029bcbdfd7d3f4b4
2015-10-02 16:23:44 -07:00
Adam Powell
63b3169845 Add animation and positional stability to intent chooser UI
Dejank the process of bringing in new ChooserTargets from queried
services. Animate the service target rows in upward so that if the
user's finger is already headed for a visible choice we don't inject
something wrong right under them at the last second. Keep things sane
if the user is dragging the UI while we're bringing in new items.

To animate this, since we can't use RecyclerView from the framework we
treat the height of rows as a conceptual data set change for
ListView. To get away with doing this per-frame we pre-measure the
item height (which remains constant) instead of doing more expensive
wrap_content calculations. ResolverDrawerLayout is now aware of how to
account for a cheat-measured ListView to compensate.

Bug 24038066

Change-Id: I01414a5746815255ff948a6d0887bb5ad0897285
2015-10-02 19:37:29 +00:00
Adam Powell
6ef8578ef4 Add animation and positional stability to intent chooser UI
Dejank the process of bringing in new ChooserTargets from queried
services. Animate the service target rows in upward so that if the
user's finger is already headed for a visible choice we don't inject
something wrong right under them at the last second. Keep things sane
if the user is dragging the UI while we're bringing in new items.

To animate this, since we can't use RecyclerView from the framework we
treat the height of rows as a conceptual data set change for
ListView. To get away with doing this per-frame we pre-measure the
item height (which remains constant) instead of doing more expensive
wrap_content calculations. ResolverDrawerLayout is now aware of how to
account for a cheat-measured ListView to compensate.

Bug 24038066

Change-Id: I01414a5746815255ff948a6d0887bb5ad0897285
2015-10-02 12:32:24 -07:00
Skuhne
b816087962 Rendering the window frame with a second thread
Using a multi threaded render node to render the window frame
asynchronously from the application relayout.

Bug: 22527834
Bug: 24400680
Bug: 24459827
Bug: 24409773
Bug: 24537510
Change-Id: I1010fc6a8b6e38424178140afa3ca124433ab7e4
2015-10-02 07:11:45 -07:00
Chong Zhang
5482018a31 Merge "Only send touch event in NonClientDecorView to caption bar" 2015-09-30 21:18:17 +00:00
Chong Zhang
509ea6b285 Only send touch event in NonClientDecorView to caption bar
bug: 24537314
Change-Id: I3735398b2c9425b11c44f37669ba7267f9cc32bf
2015-09-30 14:12:11 -07:00
Jeff Sharkey
54c331a05b am 5dfd06f7: am c2fa99ed: am 792a9cc3: am 30fd0628: Merge "Relax auto-launch checks for GET_CONTENT." into mnc-dr-dev
* commit '5dfd06f7d00476dcffb933584ef7e083469215e3':
  Relax auto-launch checks for GET_CONTENT.
2015-09-30 20:36:50 +00:00
Jeff Sharkey
5dfd06f7d0 am c2fa99ed: am 792a9cc3: am 30fd0628: Merge "Relax auto-launch checks for GET_CONTENT." into mnc-dr-dev
* commit 'c2fa99edf1591eca47ad678889cfd4924f2470a8':
  Relax auto-launch checks for GET_CONTENT.
2015-09-30 20:27:36 +00:00
Jeff Sharkey
792a9cc3a5 am 30fd0628: Merge "Relax auto-launch checks for GET_CONTENT." into mnc-dr-dev
* commit '30fd0628970b418dea382b388120f52504ff2243':
  Relax auto-launch checks for GET_CONTENT.
2015-09-30 20:11:22 +00:00