Remove ApplicationInitialization class.

It has a single method, confusing name, and provides little/no
value.  This just inlines the single method into the one call site.

BUG=876369

Change-Id: I8cc09dec289c14764563265e1da7ab41c5e74cf3
Reviewed-on: https://chromium-review.googlesource.com/c/1394928
Reviewed-by: Theresa <twellington@chromium.org>
Commit-Queue: Ted Choc <tedchoc@chromium.org>
Cr-Commit-Position: refs/heads/master@{#619862}
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/ApplicationInitialization.java b/chrome/android/java/src/org/chromium/chrome/browser/ApplicationInitialization.java
deleted file mode 100644
index 08b1685..0000000
--- a/chrome/android/java/src/org/chromium/chrome/browser/ApplicationInitialization.java
+++ /dev/null
@@ -1,38 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-package org.chromium.chrome.browser;
-
-import android.content.res.Resources;
-import android.util.TypedValue;
-
-import org.chromium.base.CommandLine;
-import org.chromium.chrome.R;
-import org.chromium.content_public.common.ContentSwitches;
-
-/**
- * Utility class for application level initialization calls.
- */
-public final class ApplicationInitialization {
-    // Prevent instantiation.
-    private ApplicationInitialization() {
-    }
-
-    /**
-     * Enable fullscreen related startup flags.
-     * @param resources Resources to use while calculating initialization constants.
-     */
-    public static void enableFullscreenFlags(Resources resources) {
-        CommandLine commandLine = CommandLine.getInstance();
-        if (commandLine.hasSwitch(ChromeSwitches.DISABLE_FULLSCREEN)) return;
-
-        TypedValue threshold = new TypedValue();
-        resources.getValue(R.dimen.top_controls_show_threshold, threshold, true);
-        commandLine.appendSwitchWithValue(
-                ContentSwitches.TOP_CONTROLS_SHOW_THRESHOLD, threshold.coerceToString().toString());
-        resources.getValue(R.dimen.top_controls_hide_threshold, threshold, true);
-        commandLine.appendSwitchWithValue(
-                ContentSwitches.TOP_CONTROLS_HIDE_THRESHOLD, threshold.coerceToString().toString());
-    }
-}
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/ChromeActivity.java b/chrome/android/java/src/org/chromium/chrome/browser/ChromeActivity.java
index b560932..06fe4b1 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/ChromeActivity.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/ChromeActivity.java
@@ -25,6 +25,7 @@
 import android.support.annotation.Nullable;
 import android.util.DisplayMetrics;
 import android.util.Pair;
+import android.util.TypedValue;
 import android.view.Menu;
 import android.view.MenuItem;
 import android.view.View;
@@ -343,7 +344,17 @@
         // not go through ChromeLauncherActivity that would have normally triggered this.
         mPartnerBrowserRefreshNeeded = !PartnerBrowserCustomizations.isInitialized();
 
-        ApplicationInitialization.enableFullscreenFlags(getResources());
+        CommandLine commandLine = CommandLine.getInstance();
+        if (!commandLine.hasSwitch(ChromeSwitches.DISABLE_FULLSCREEN)) {
+            TypedValue threshold = new TypedValue();
+            getResources().getValue(R.dimen.top_controls_show_threshold, threshold, true);
+            commandLine.appendSwitchWithValue(ContentSwitches.TOP_CONTROLS_SHOW_THRESHOLD,
+                    threshold.coerceToString().toString());
+            getResources().getValue(R.dimen.top_controls_hide_threshold, threshold, true);
+            commandLine.appendSwitchWithValue(ContentSwitches.TOP_CONTROLS_HIDE_THRESHOLD,
+                    threshold.coerceToString().toString());
+        }
+
         getWindow().setBackgroundDrawable(getBackgroundDrawable());
 
         mFullscreenManager = createFullscreenManager();
diff --git a/chrome/android/java_sources.gni b/chrome/android/java_sources.gni
index 52c084bc..530b0ad2 100644
--- a/chrome/android/java_sources.gni
+++ b/chrome/android/java_sources.gni
@@ -18,7 +18,6 @@
   "java/src/org/chromium/chrome/browser/AppHooks.java",
   "java/src/org/chromium/chrome/browser/AppHooksModule.java",
   "java/src/org/chromium/chrome/browser/AppIndexingUtil.java",
-  "java/src/org/chromium/chrome/browser/ApplicationInitialization.java",
   "java/src/org/chromium/chrome/browser/ApplicationLifetime.java",
   "java/src/org/chromium/chrome/browser/AssistStatusHandler.java",
   "java/src/org/chromium/chrome/browser/BackgroundSyncLauncher.java",