Ensure minimized state is false when dock is gone on exists change

Whenever registerDockedStackListener runs, it will unminimize the docked
stack even if it was not supposed to. The previous change that caused
this was the test ag/1718898,
ActivityManagerDockedStackTests#testFinishDockActivityWhileMinimized
where an activity runs finish() while minimized would remove the
divider but not update the minimized mode. This change will only set the
minimized mode to false if the divider is invisible allowing
registerDockedStackListener to not unminimize.

Fixes: 62460975
Test: go/wm-smoke
Test: cts/hostsidetests/services/activityandwindowmanager/util/run-test
CtsServicesHostTestCases
android.server.cts.ActivityManagerDockedStackTests#
testFinishDockActivityWhileMinimized
Change-Id: I2baaac9ce50b8ed792356cbaeeedef6bddc271d3
1 file changed