diff options
author | Ben Lin <linben@google.com> | 2020-11-05 11:16:05 -0800 |
---|---|---|
committer | Ben Lin <linben@google.com> | 2020-11-05 18:28:06 -0800 |
commit | d4459553dcbff6d48c48a4fcfeb008b244697a90 (patch) | |
tree | d8bdb37300607d17f37255ac9b75c39f181510c4 /rs/java/android/renderscript/ProgramFragmentFixedFunction.java | |
parent | dd6d27ec2b9b346a41aa51b3cd483eb7ef58905b (diff) |
Move attach/detach PiP menu calls to onTaskAppear/Vanish.
In an ideal case, onActivityPinned should always be followed by
an onActivityUpinned call in a PiP session. However, there are
possible times where it doesn't happen; PIP can crash suddenly,
or some other calls force closes PiP without it
getting a chance to call on Unpinned. In that case, menu isn't properly
cleaned up, so let's just make sure it is before trying to re-attach.
At the same time, move the call to onTaskAppear/Vanish, which is
guaranteed to be called.
Bug: 172268911
Bug: 172258041
Bug: 170315895
Test: Manual; Pause PiP, unpause PiP, menu still showing
Test: Locally hack so that detach doesn't get called the first time
(simulate crash), start PiP again - doesn't crash
Change-Id: I76984de59515f4178561ba92ae692fcc3c5edcb9
Diffstat (limited to 'rs/java/android/renderscript/ProgramFragmentFixedFunction.java')
0 files changed, 0 insertions, 0 deletions