Skip to content

Commit

Permalink
Fix issue with child controllers frozen at detach time not re-attaching
Browse files Browse the repository at this point in the history
  • Loading branch information
EricKuck committed Aug 15, 2023
1 parent 4d4d8bf commit a90ca51
Showing 1 changed file with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1387,11 +1387,17 @@ final void setDetachFrozen(boolean frozen) {
if (isDetachFrozen != frozen) {
isDetachFrozen = frozen;

boolean detach = !frozen && view != null && viewWasDetached;

for (ControllerHostedRouter router : childRouters) {
if (detach) {
router.prepareForHostDetach();
}

router.setDetachFrozen(frozen);
}

if (!frozen && view != null && viewWasDetached) {
if (detach) {
View aView = view;
detach(view, false, false);
if (view == null && aView.getParent() == router.container) {
Expand Down

0 comments on commit a90ca51

Please sign in to comment.