[ios] Removes the launch screen when showing the tab switcher.

This was accidentally dropped during a rebase of
https://chromium-review.googlesource.com/c/chromium/src/+/920521/4.

BUG=803758,813712

Cq-Include-Trybots: master.tryserver.chromium.mac:ios-simulator-cronet;master.tryserver.chromium.mac:ios-simulator-full-configs
Change-Id: Ic60756a3a0cef504ceb9506461be8cf16b0a26c2
Reviewed-on: https://chromium-review.googlesource.com/941908
Reviewed-by: edchin <edchin@chromium.org>
Reviewed-by: Mark Cogan <marq@chromium.org>
Commit-Queue: Rohit Rao <rohitrao@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#540002}(cherry picked from commit d7b61d89e336180d4dcc1779e7959fe14b5710f9)
Reviewed-on: https://chromium-review.googlesource.com/943201
Reviewed-by: Rohit Rao <rohitrao@chromium.org>
Cr-Commit-Position: refs/branch-heads/3325@{#637}
Cr-Branched-From: bc084a8b5afa3744a74927344e304c02ae54189f-refs/heads/master@{#530369}
diff --git a/ios/chrome/browser/ui/main/main_presenting_view_controller.mm b/ios/chrome/browser/ui/main/main_presenting_view_controller.mm
index 1a1a7eb..0ea6678 100644
--- a/ios/chrome/browser/ui/main/main_presenting_view_controller.mm
+++ b/ios/chrome/browser/ui/main/main_presenting_view_controller.mm
@@ -147,6 +147,12 @@
              completion:(ProceduralBlock)completion {
   DCHECK(tabSwitcher);
 
+  // Before any child view controller would be added, remove the launch screen.
+  if (self.launchScreen) {
+    [self.launchScreen removeFromSuperview];
+    self.launchScreen = nil;
+  }
+
   // Don't remove and re-add the tabSwitcher if it hasn't changed.
   if (self.tabSwitcher != tabSwitcher) {
     // Remove any existing tab switchers first.