The flake was caused by the fact that addOnDrawListener(), the redraw is not guaranteed. This ultimately results to the workspace loading never finishing.
Forcing the redraw.
Bug: 267200150
Test: atest Launcher3Tests:com.android.launcher3.celllayout.ReorderWidgets#simpleReorder --rerun-until-failure
Flag: N/A
Change-Id: I47683425150a07ab2632e2bebdeca4d304e30d1b
Removing debug logs for bugs that have already been closed. These logs are filling up the logcat buffer and impeding in other test investigations.
Flag: not needed
Test: Tapl tests
Bug: 260260325
Change-Id: I4d69b904f2ea79d758cf6bef7d90d172f2eb2a91
> Making all methods as default
> Removing obsolete logic around synchronous binding
> Removing some UI dependencies from bind callbacks
Bug: 187353581
Test: Manual
Change-Id: I0d2bbb060af2cab7c64541d7695055629dfaf0b8
If attachTo happens before the view is attached to window,
ViewOnDrawExecutor hooks to the tree observer twice (second time from
onViewAttachedToWindow). It only unhooks once.
Since tree observer is global, this leads to leaking the activity, and
besides, all old activities getting the events from the tree observer.
Bug: 139137636
Change-Id: Ie2641b8f3614545052fe34ad6588b070c3b82a33
before marking the ViewOnDrawExecutor as completed.
Also fixing model writer not updated on rotation
Change-Id: I5ecd7ac865b939ffa4c02afe892bd773d9f275c3
- If there is any delay in launcher draw, then we will finish the
transition and hide the app window before launcher has had a chance to
draw the task view with the updated snapshot.
Change-Id: I81c5b467f32520fd7474bde0e89819336292e84f
Defer:
- Setting all apps
- Setting widgets
Also set the launcher-loader thread to THREAD_PRIORITY_BACKGROUND
for the duration of the animation.
Bug: 37965432
Change-Id: I8364940805b84aecb8353a473ab4d575c27bfec4
DeferredHandler was added when we were posting each icon separately,
to prevent starvation. But since then we have moved to binding batct
items during bind.
Also fixing waitForIdle not waiting the second time. waitForIdle was
using a global variable to maintain state, and was not waiting properly
when its called the second time before binding deep shortcuts
Original Change-Id: I9c1289cb3bfb74f86e53ec7ac6dd76bb39666b2d
Change-Id: I9e6b3ae65fbd3aec3a46092efc5249c4525efedf
> Using ViewTreeObserver to listen for onDraw instead of overriding onDraw in workspace
> Loader passes the list of deferrerd runnables to launcher
Change-Id: Ie4877f746c96e9497396de8089f00f70bf867e17