Commit ea3be622 authored by mthiesse's avatar mthiesse Committed by Commit bot

Remove VR mode preventing CTA from destroying incognito profile.

VR no longer uses an HTML UI, so no longer uses the incognito profile.

BUG=

Review-Url: https://codereview.chromium.org/2845023003
Cr-Commit-Position: refs/heads/master@{#467975}
parent f2ffcffa
......@@ -453,7 +453,6 @@ public class ChromeTabbedActivity extends ChromeActivity implements OverviewMode
@SuppressLint("NewApi")
private boolean shouldDestroyIncognitoProfile() {
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.LOLLIPOP) return false;
if (VrShellDelegate.isInVr()) return false; // VR uses an incognito profile for rendering.
Context context = ContextUtils.getApplicationContext();
ActivityManager manager =
......@@ -1985,12 +1984,6 @@ public class ChromeTabbedActivity extends ChromeActivity implements OverviewMode
public void onExitVr() {
super.onExitVr();
mControlContainer.setVisibility(View.VISIBLE);
// We prevent the incognito profile from being destroyed while in VR, so upon exiting VR we
// should destroy it if necessary.
if (shouldDestroyIncognitoProfile()) {
Profile.getLastUsedProfile().getOffTheRecordProfile().destroyWhenAppropriate();
}
}
/**
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment