ProfileSelectDialog no longer removes caller activity from task.
In Settings, after calling ProfileSelectDialog and choosing a profile, then going back would go 2 activities back. The issue is that ProfileSelectDialog was calling finish() in the no-longer-used SettingsDrawerActivity. This caused the any activity calling the dialog to be removed from the task, and thus being impossible to go back to. This call to the drawer is also a code smell. Bug: 36237246 Fixes: 36237246 Test: NA Change-Id: I6f309b220ffae1d86e6879ddf6a0305ad3dde3e8
This commit is contained in:
@@ -68,10 +68,8 @@ public class ProfileSelectDialog extends DialogFragment implements OnClickListen
|
||||
public void onClick(DialogInterface dialog, int which) {
|
||||
UserHandle user = mSelectedTile.userHandle.get(which);
|
||||
// Show menu on top level items.
|
||||
mSelectedTile.intent.putExtra(SettingsDrawerActivity.EXTRA_SHOW_MENU, true);
|
||||
mSelectedTile.intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TASK);
|
||||
getActivity().startActivityAsUser(mSelectedTile.intent, user);
|
||||
((SettingsDrawerActivity) getActivity()).onProfileTileOpen();
|
||||
}
|
||||
|
||||
public static void updateUserHandlesIfNeeded(Context context, Tile tile) {
|
||||
|
||||
Reference in New Issue
Block a user