360 Commits

Author SHA1 Message Date
Chet Haase
28e8db1940 am 43757cc8: am 2a8eaff4: am c9d8e383: Merge "Fix leak with transitions when views get removed" into klp-dev
* commit '43757cc8438e85bf0633580c660c4861338f1da2':
  Fix leak with transitions when views get removed
2013-10-23 12:30:20 -07:00
Chet Haase
43757cc843 am 2a8eaff4: am c9d8e383: Merge "Fix leak with transitions when views get removed" into klp-dev
* commit '2a8eaff4ec10f5d554043c73c0e3424186e09a8a':
  Fix leak with transitions when views get removed
2013-10-23 12:27:27 -07:00
Chet Haase
df32aa8715 Fix leak with transitions when views get removed
Transitions, when started, add an OnPreDrawListener to the current
ViewTreeObserver (which is global to the view hierarchy). This listener
is removed when the listener is called.

It is possible to add this listener and then remove the view from
the hierarchy before the listener is called. This could result in
either the listener not getting called at all (since there was no
drawing event) or (in the case of this bug) the listener getting called
when the sceneRoot had no AttachInfo (which is the case when that
root has been removed from the hierarchy). This results in the listener
trying to remove itself from a *different* ViewTreeObserver than the one
it added itself to, leaving the actual listener still sitting on a list
of listeners in that original VTO. This can result in a growing list of
listeners and a growing amount of work that gets done on every frame.
It can also lead to a serious memory leak, since the objects referred to
by the transition may be non-trivial (as in the case of this bug).

The fix is to add another mechanism for the listener to get removed.
Specifically, we now listen for detach events on the sceneRoot. If that
view gets detached before the listener is called, then we have a chance to
remove it from the correct VTO before the AttachInfo becomes null.

Issue #11307391 keyguard is slow after updating to krt16c and playing music

Change-Id: I108413ea2f18f5351df0a11d4ae56fec0b4aa154
2013-10-22 16:27:56 -07:00
Jim Miller
85d7ecfa4b am 6ed3ce0b: am 253f7295: am 1693f6a5: Prevent having multiple seek runnables in flight.
* commit '6ed3ce0b71b8d2c180fc9f610eb13cd35dc8ab5e':
  Prevent having multiple seek runnables in flight.
2013-10-21 17:30:29 -07:00
Jim Miller
6ed3ce0b71 am 253f7295: am 1693f6a5: Prevent having multiple seek runnables in flight.
* commit '253f7295c820bf960c0411288495145582a0d3b2':
  Prevent having multiple seek runnables in flight.
2013-10-21 17:27:25 -07:00
Jim Miller
1693f6a563 Prevent having multiple seek runnables in flight.
This fix ensures that only one runnable is running at a time, no matter how
many events come in.  There's probably a better way to do this, but this is a
safe fix.

Fixes bug 11307391

Change-Id: I007c95062b20285571f39603c95fb9174b9a2da3
2013-10-21 17:17:40 -07:00
Jim Miller
74ec0ca98b am 059d89a1: am 262e5281: am 644696f0: Merge "Workaround for corner case in TransitionManager" into klp-dev
* commit '059d89a1a447095deaa80a0378f822cb25547c70':
  Workaround for corner case in TransitionManager
2013-10-21 16:17:59 -07:00
Jim Miller
059d89a1a4 am 262e5281: am 644696f0: Merge "Workaround for corner case in TransitionManager" into klp-dev
* commit '262e5281d7d678c765ae2500dc05c742946c716b':
  Workaround for corner case in TransitionManager
2013-10-21 16:14:58 -07:00
Jim Miller
ee186de4b2 Workaround for corner case in TransitionManager
This works around a problem where removing a review with unfinished
transitions results in leaked object references to KeyguardTransportControlView.

The workaround disables transitions until we have a better fix.

Fixes bug 11307391

Change-Id: I1df82f2c6f1cd9f5c9076d4c76cfd4aec3b6806c
2013-10-21 15:36:54 -07:00
Alan Viverette
f7e6c3cb8a am 5c675074: am c5aa0ab2: am ba551061: Merge "Don\'t clip keyguard security container children (e.g. glow pad)" into klp-dev
* commit '5c675074c774c4e260f738b52eca47fe9f3e6ffa':
  Don't clip keyguard security container children (e.g. glow pad)
2013-10-21 13:57:51 -07:00
Alan Viverette
5c675074c7 am c5aa0ab2: am ba551061: Merge "Don\'t clip keyguard security container children (e.g. glow pad)" into klp-dev
* commit 'c5aa0ab2e8c47f0d16077abec1531998fbc5b415':
  Don't clip keyguard security container children (e.g. glow pad)
2013-10-21 13:55:51 -07:00
Alan Viverette
ba55106148 Merge "Don't clip keyguard security container children (e.g. glow pad)" into klp-dev 2013-10-21 20:48:57 +00:00
Jim Miller
332eb8f7eb am 51e4f391: am 495bd54c: am 42b7b692: Merge "Revert "Fix dodgy states of keyguard transport controls"" into klp-dev
* commit '51e4f391717deb24ea7b22096df2ddb5535aee00':
  Revert "Fix dodgy states of keyguard transport controls"
2013-10-18 18:17:47 -07:00
Jim Miller
51e4f39171 am 495bd54c: am 42b7b692: Merge "Revert "Fix dodgy states of keyguard transport controls"" into klp-dev
* commit '495bd54c630691811e051247eec87e097c0bb01c':
  Revert "Fix dodgy states of keyguard transport controls"
2013-10-18 18:14:07 -07:00
Jim Miller
42b7b6927c Merge "Revert "Fix dodgy states of keyguard transport controls"" into klp-dev 2013-10-19 01:08:12 +00:00
Jim Miller
4d20ed3f26 Revert "Fix dodgy states of keyguard transport controls"
This reverts commit bdb5ac7ddbabec0ba947a32937d8b95738d513dc.

Change-Id: Iea8db9a590a2a3b65d941b2918345eb27f690240
2013-10-19 01:00:16 +00:00
Jim Miller
e400a2900d am 53caf875: am 01491271: am 53cb242f: Merge "Fix issue where keyguard adds widgets before the system is ready" into klp-dev
* commit '53caf87531372048d4171626e767eeeb94ec664c':
  Fix issue where keyguard adds widgets before the system is ready
2013-10-17 16:27:02 -07:00
Jim Miller
53caf87531 am 01491271: am 53cb242f: Merge "Fix issue where keyguard adds widgets before the system is ready" into klp-dev
* commit '0149127198f9fc46a3a4f0b7f4e9579b72273b46':
  Fix issue where keyguard adds widgets before the system is ready
2013-10-17 16:23:13 -07:00
Jim Miller
53cb242f39 Merge "Fix issue where keyguard adds widgets before the system is ready" into klp-dev 2013-10-17 23:17:19 +00:00
Adam Powell
d21b70322a am 16f495df: am 11c746ab: am a9412556: Merge "Fix stale data in keyguard transport control display" into klp-dev
* commit '16f495dfa43a9e51e3964511c9d6e5567528587d':
  Fix stale data in keyguard transport control display
2013-10-17 10:41:19 -07:00
Adam Powell
16f495dfa4 am 11c746ab: am a9412556: Merge "Fix stale data in keyguard transport control display" into klp-dev
* commit '11c746abf3793cf122a353dbee1d73e2eddbfb82':
  Fix stale data in keyguard transport control display
2013-10-17 10:35:17 -07:00
Adam Powell
a9412556d2 Merge "Fix stale data in keyguard transport control display" into klp-dev 2013-10-17 17:29:52 +00:00
Jim Miller
e5f910a667 Fix issue where keyguard adds widgets before the system is ready
While under heavy system load,  keyguard was able to create widgets before
before ActivityManagerService was ready.  The result was a race
between keyguard adding widgets and ActivityManagerService being
ready to send broadcasts.

This fix provides keyguard with an additional signal to know when
the system is booted and widgets are safe to load.

Fixes bug b/11217169

Change-Id: I7a714d65b068678f961e52bdde4e1c20f9c287f0
2013-10-16 19:42:34 -07:00
Jim Miller
805f7a1d01 am a4738bdb: am 7c95ae91: am 67fc6b0b: Merge "Fix issue where keyguard reports a valid token but doesn\'t draw" into klp-dev
* commit 'a4738bdbd2d310842bc55aecfcd5105ade83e146':
  Fix issue where keyguard reports a valid token but doesn't draw
2013-10-16 00:13:46 -07:00
Jim Miller
a4738bdbd2 am 7c95ae91: am 67fc6b0b: Merge "Fix issue where keyguard reports a valid token but doesn\'t draw" into klp-dev
* commit '7c95ae91b69a1aaae8e0ec41d0e76c66ee52f31a':
  Fix issue where keyguard reports a valid token but doesn't draw
2013-10-16 00:10:31 -07:00
Jim Miller
67fc6b0b47 Merge "Fix issue where keyguard reports a valid token but doesn't draw" into klp-dev 2013-10-16 07:05:22 +00:00
Jim Miller
c9cc6907ac am 5e3ab35c: am f3cad918: am db148b65: Merge "Fix memory leak and slowness in keyguard" into klp-dev
* commit '5e3ab35c0aaadcec496d18d1a66e79c35a7f8ffd':
  Fix memory leak and slowness in keyguard
2013-10-15 21:00:33 -07:00
Jim Miller
5e3ab35c0a am f3cad918: am db148b65: Merge "Fix memory leak and slowness in keyguard" into klp-dev
* commit 'f3cad9184f6ef56be403369d87fd0fa1cbd9de86':
  Fix memory leak and slowness in keyguard
2013-10-15 20:58:27 -07:00
Jim Miller
db148b6556 Merge "Fix memory leak and slowness in keyguard" into klp-dev 2013-10-16 03:52:10 +00:00
Jim Miller
b2c64690a3 Fix memory leak and slowness in keyguard
This fixes an issue where the mUpdateSeekBars runnable was being
repeatedly posted to the handler while keeping a reference to
the transport control (and hence keyguard).  Even after the view
was detached from keyguard it would continue to post events that
would ultimately keep the instance of keyguard from being GC'd and
cause keyguard to slow down.

Fixes 11169793

Change-Id: If2bb238adf6d78101589926b60a61d9f187c6d1c
2013-10-15 20:11:50 -07:00
Adam Powell
3b435fb2f0 Fix stale data in keyguard transport control display
Make sure that caches are cleared at the right times and views have
their data populated correctly. Also fix a caching issue in
RemoteController.

Bug 11218218

Change-Id: Ieb833b5dc440ccd1b82050f12eb7059a4e0a412f
2013-10-15 19:18:04 -07:00
Adam Powell
4a99019d66 am 1af10256: am cb13a546: am 49b6d38f: Merge "Fix dodgy states of keyguard transport controls" into klp-dev
* commit '1af10256cd07c2c096e22038379210866dff82a2':
  Fix dodgy states of keyguard transport controls
2013-10-15 18:48:37 -07:00
Adam Powell
1af10256cd am cb13a546: am 49b6d38f: Merge "Fix dodgy states of keyguard transport controls" into klp-dev
* commit 'cb13a5460495d7b05e1667397166330bb3ac412a':
  Fix dodgy states of keyguard transport controls
2013-10-15 18:44:47 -07:00
Adam Powell
49b6d38fe7 Merge "Fix dodgy states of keyguard transport controls" into klp-dev 2013-10-16 01:41:22 +00:00
Adam Powell
bdb5ac7ddb Fix dodgy states of keyguard transport controls
If a layout has already been requested when we want to show the
correct widget pane, post the event for later and immediately return.

This works because PagedView has some interesting ideas about
maintaining a consistent state. It will attempt to recalculate the
current page position during measurement, but thanks to a reliance on
this measurement to establish scrolling boundaries that scrollTo uses
for clamping plus other code that depends on the idea that it can add
a new widget pane view and immediately scroll to it, this attempt to
scroll fails if the target page was added and measurement is not yet
complete. This patch ensures we don't hit these edge cases in a few
known ways.

While this ends things in the correct state, it predictably has a few
visual artifacts. Situations where things would completely fail
before, positioning pages incorrectly or fading out wrong pages now
will briefly flash and fade the widget frames or in some cases will
visibly animate from the starting page to the correct one. We should
address these issues in a future release.

Bug 11217368
Bug 9760604

Change-Id: I989d03b5bfdd5b6403a6b67a8aae7585ca0c8ae0
2013-10-15 18:10:41 -07:00
Jim Miller
ed80f3f01e Fix issue where keyguard reports a valid token but doesn't draw
This fixes an issue where keyguard isn't showing but tells
PhoneWindowManager to wait anyway.  The fix is to send a null token
when keyguard isn't showing.

Fixes bug 11216030

Change-Id: I4985fe50c63819415d9d5a1de0b741c8aa6391d8
2013-10-15 17:50:17 -07:00
Jim Miller
7041bd2c42 am 35077089: am d5bda747: am 2cc95775: Merge "Fix possible crash in System UI" into klp-dev
* commit '3507708905e2d4aced05ece0d157ee9def40b624':
  Fix possible crash in System UI
2013-10-15 17:29:46 -07:00
Jim Miller
3507708905 am d5bda747: am 2cc95775: Merge "Fix possible crash in System UI" into klp-dev
* commit 'd5bda747971db5fc2dde78dcc5bb42e62659667d':
  Fix possible crash in System UI
2013-10-15 16:17:06 -07:00
Jim Miller
2cc9577575 Merge "Fix possible crash in System UI" into klp-dev 2013-10-15 21:44:48 +00:00
Jim Miller
faaa3654d1 Fix possible crash in System UI
Fixes bug 11215581

Change-Id: Ic76ad783729316539e8e57feb098d6e823b4ecdf
2013-10-15 13:46:51 -07:00
Jim Miller
2836cd74a9 am fc6625db: am 2399d6a4: am 7f988c2b: Merge "Don\'t move clock when warping in PagedView" into klp-dev
* commit 'fc6625db32412e3416287d160d2334e25a36d37f':
  Don't move clock when warping in PagedView
2013-10-15 05:05:15 -07:00
Jim Miller
14d9a02506 am 566c4a0b: am 6915644d: am f7b75eeb: Merge "Add additional MNC overlays" into klp-dev
* commit '566c4a0bc55958b196c6503e95112e2b288a9f4a':
  Add additional MNC overlays
2013-10-15 04:02:04 -07:00
Jim Miller
fc6625db32 am 2399d6a4: am 7f988c2b: Merge "Don\'t move clock when warping in PagedView" into klp-dev
* commit '2399d6a4f0d14e118ab706777753d3e2a5657dbc':
  Don't move clock when warping in PagedView
2013-10-14 19:08:04 -07:00
Jim Miller
566c4a0bc5 am 6915644d: am f7b75eeb: Merge "Add additional MNC overlays" into klp-dev
* commit '6915644d5b978706e147ae1fc4f91bb3d3641c11':
  Add additional MNC overlays
2013-10-14 19:00:17 -07:00
Jim Miller
7f988c2bbb Merge "Don't move clock when warping in PagedView" into klp-dev 2013-10-15 01:57:25 +00:00
Jim Miller
1c058a68e9 Don't move clock when warping in PagedView
This fixes a bug where the clock would appear to move when flinging
the camera widget while warping.  To accomplish this,  it no longer
scrolls while warping but rather updates the warp view's translationX.
When the finger is released or a fling happens, we either smoothly
animate the view back (without scrolling) or update the scroll position
and let the scroller take over the animation.

Fixes bug 11191094

Change-Id: I33f087cf4fb2ec31db11d69d11055b513604b1d1
2013-10-14 16:09:50 -07:00
Jim Miller
0ed6d68496 Add additional MNC overlays
Fixes bug 10518893

Change-Id: If8f46202f593e545fe38c4803481b266b60543b9
2013-10-14 13:57:46 -07:00
Jim Miller
53e711fff6 am 7c4f3b81: am a55feec8: am f89ff85f: Merge "Hide the camera and search icons when switching to the camera page" into klp-dev
* commit '7c4f3b8134c9fa4403d070161930623efa9ac577':
  Hide the camera and search icons when switching to the camera page
2013-10-14 10:52:52 -07:00
Jim Miller
f6dd090d98 am 91feb766: am 43b0ce62: am 05da3280: Merge "Fix warp animation in keyguard" into klp-dev
* commit '91feb766f9b1f121611d26931e6cd65e46ddfd01':
  Fix warp animation in keyguard
2013-10-14 10:52:48 -07:00
Jim Miller
e23ced5ecc am 51171688: am 7f210cbb: am 103a734b: Merge "Fix bug where lockout timeout is shown for SIM in keyguard" into klp-dev
* commit '51171688154947124fe8868cdcd43fbbe4fff495':
  Fix bug where lockout timeout is shown for SIM in keyguard
2013-10-14 10:52:29 -07:00