Backed out changeset 3c03b94342b9 (bug 1329152)
authorCarsten "Tomcat" Book <cbook@mozilla.com>
Mon, 12 Jun 2017 08:57:45 +0200
changeset 411528 3c60b0f8edb0f107d05f1a1822ac47a284c8f35c
parent 411527 042829191d730dd6e901d09fb62bbf4274fe5895
child 411529 27cad9749cddf68e11fdd4e5d73dad84a8f8cf23
push id7391
push usermtabara@mozilla.com
push dateMon, 12 Jun 2017 13:08:53 +0000
treeherdermozilla-beta@2191d7f87e2e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1329152
milestone55.0a1
backs out3c03b94342b95c9fdf8e7a2e36b1e30e051e8d5c
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Backed out changeset 3c03b94342b9 (bug 1329152)
mobile/android/base/java/org/mozilla/gecko/Experiments.java
mobile/android/base/java/org/mozilla/gecko/LauncherActivity.java
--- a/mobile/android/base/java/org/mozilla/gecko/Experiments.java
+++ b/mobile/android/base/java/org/mozilla/gecko/Experiments.java
@@ -60,19 +60,16 @@ public class Experiments {
     public static final String ACTIVITY_STREAM = "activity-stream";
 
     // Show a setting in "experimental features" for enabling/disabling activity stream.
     public static final String ACTIVITY_STREAM_SETTING = "activity-stream-setting";
 
     // Enable Activity stream by default for users in the "opt out" group.
     public static final String ACTIVITY_STREAM_OPT_OUT = "activity-stream-opt-out";
 
-    // User in this group will enable Custom Tabs
-    public static final String CUSTOM_TABS = "custom-tabs";
-
     // Tabs tray: Arrange tabs in two columns in portrait mode
     public static final String COMPACT_TABS = "compact-tabs";
 
     // Enable full bookmark management(full-page dialog, bookmark/folder modification, etc.)
     public static final String FULL_BOOKMARK_MANAGEMENT = "full-bookmark-management";
 
     // Enable Leanplum SDK
     public static final String LEANPLUM = "leanplum-start";
--- a/mobile/android/base/java/org/mozilla/gecko/LauncherActivity.java
+++ b/mobile/android/base/java/org/mozilla/gecko/LauncherActivity.java
@@ -1,26 +1,24 @@
 /* -*- Mode: Java; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: nil; -*-
  * This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 package org.mozilla.gecko;
 
 import android.app.Activity;
-import android.content.Context;
 import android.content.Intent;
 import android.net.Uri;
 import android.os.Bundle;
 import android.support.annotation.NonNull;
 import android.support.customtabs.CustomTabsIntent;
 import android.util.Log;
 
 import org.mozilla.gecko.home.HomeConfig;
-import org.mozilla.gecko.switchboard.SwitchBoard;
 import org.mozilla.gecko.webapps.WebAppActivity;
 import org.mozilla.gecko.webapps.WebAppIndexer;
 import org.mozilla.gecko.customtabs.CustomTabsActivity;
 import org.mozilla.gecko.db.BrowserContract;
 import org.mozilla.gecko.mozglue.SafeIntent;
 import org.mozilla.gecko.preferences.GeckoPreferences;
 import org.mozilla.gecko.tabqueue.TabQueueHelper;
 import org.mozilla.gecko.tabqueue.TabQueueService;
@@ -62,17 +60,17 @@ public class LauncherActivity extends Ac
         // Is this web app?
         } else if (isWebAppIntent(safeIntent)) {
             dispatchWebAppIntent();
 
         // If it's not a view intent, it won't be a custom tabs intent either. Just launch!
         } else if (!isViewIntentWithURL(safeIntent)) {
             dispatchNormalIntent();
 
-        } else if (isCustomTabsIntent(safeIntent) && isCustomTabsEnabled(this) ) {
+        } else if (isCustomTabsIntent(safeIntent)) {
             dispatchCustomTabsIntent();
 
         // Can we dispatch this VIEW action intent to the tab queue service?
         } else if (!safeIntent.getBooleanExtra(BrowserContract.SKIP_TAB_QUEUE_FLAG, false)
                 && TabQueueHelper.TAB_QUEUE_ENABLED
                 && TabQueueHelper.isTabQueueEnabled(this)) {
             dispatchTabQueueIntent();
 
@@ -144,20 +142,16 @@ public class LauncherActivity extends Ac
         intent.setFlags(intent.getFlags() & ~Intent.FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS);
     }
 
     private static boolean isViewIntentWithURL(@NonNull final SafeIntent safeIntent) {
         return Intent.ACTION_VIEW.equals(safeIntent.getAction())
                 && safeIntent.getDataString() != null;
     }
 
-    private static boolean isCustomTabsEnabled(@NonNull final Context context) {
-        return SwitchBoard.isInExperiment(context, Experiments.CUSTOM_TABS);
-    }
-
     private static boolean isCustomTabsIntent(@NonNull final SafeIntent safeIntent) {
         return isViewIntentWithURL(safeIntent)
                 && safeIntent.hasExtra(CustomTabsIntent.EXTRA_SESSION);
     }
 
     private static boolean isWebAppIntent(@NonNull final SafeIntent safeIntent) {
         return GeckoApp.ACTION_WEBAPP.equals(safeIntent.getAction());
     }