Fix enterprise settings bug
This fixes a bug where the picker is not using the correct user id and also ensures that the settings activity uses the correct user when launched. Test: flash & test w/ work profile Bug 322071206 Change-Id: I846593ff9ae320d9bb774e3e79ed9ef41f101ff5
This commit is contained in:
@@ -20,7 +20,6 @@ import static androidx.lifecycle.Lifecycle.Event.ON_CREATE;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.app.Dialog;
|
||||
import android.content.ActivityNotFoundException;
|
||||
import android.content.ComponentName;
|
||||
import android.content.ContentResolver;
|
||||
import android.content.Context;
|
||||
@@ -653,16 +652,8 @@ public class CredentialManagerPreferenceController extends BasePreferenceControl
|
||||
|
||||
@Override
|
||||
public void onLeftSideClicked() {
|
||||
Intent settingsIntent =
|
||||
CombinedProviderInfo.createSettingsActivityIntent(
|
||||
mContext, packageName, settingsActivity, getUser());
|
||||
if (settingsIntent != null) {
|
||||
try {
|
||||
mContext.startActivity(settingsIntent);
|
||||
} catch (ActivityNotFoundException e) {
|
||||
Log.e(TAG, "Failed to open settings activity", e);
|
||||
}
|
||||
}
|
||||
CombinedProviderInfo.launchSettingsActivityIntent(
|
||||
mContext, packageName, settingsActivity, getUser());
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user