For #24051 - Remove showStartOnHomeSettings feature flag

upstream-sync
Gabriel Luong 2 years ago committed by mergify[bot]
parent 4becaaa8cc
commit 09101eb787

@ -23,11 +23,6 @@ object FeatureFlags {
*/ */
val addressesFeature = Config.channel.isNightlyOrDebug val addressesFeature = Config.channel.isNightlyOrDebug
/**
* Enables the Start On Home feature in the settings page.
*/
const val showStartOnHomeSettings = true
/** /**
* Enables the "recent" tabs feature in the home screen. * Enables the "recent" tabs feature in the home screen.
*/ */

@ -241,9 +241,7 @@ open class HomeActivity : LocaleAwareAppCompatActivity(), NavHostActivity {
if (!shouldStartOnHome() && shouldNavigateToBrowserOnColdStart(savedInstanceState)) { if (!shouldStartOnHome() && shouldNavigateToBrowserOnColdStart(savedInstanceState)) {
navigateToBrowserOnColdStart() navigateToBrowserOnColdStart()
} else { } else {
if (FeatureFlags.showStartOnHomeSettings) { components.analytics.metrics.track(Event.StartOnHomeEnterHomeScreen)
components.analytics.metrics.track(Event.StartOnHomeEnterHomeScreen)
}
} }
Performance.processIntentIfPerformanceTest(intent, this) Performance.processIntentIfPerformanceTest(intent, this)
@ -1011,9 +1009,6 @@ open class HomeActivity : LocaleAwareAppCompatActivity(), NavHostActivity {
* links from an external apps should always opened in the [BrowserFragment]. * links from an external apps should always opened in the [BrowserFragment].
*/ */
fun shouldStartOnHome(intent: Intent? = this.intent): Boolean { fun shouldStartOnHome(intent: Intent? = this.intent): Boolean {
if (!FeatureFlags.showStartOnHomeSettings) {
return false
}
return components.strictMode.resetAfter(StrictMode.allowThreadDiskReads()) { return components.strictMode.resetAfter(StrictMode.allowThreadDiskReads()) {
// We only want to open on home when users tap the app, // We only want to open on home when users tap the app,
// we want to ignore other cases when the app gets open by users clicking on links. // we want to ignore other cases when the app gets open by users clicking on links.

@ -537,9 +537,7 @@ class HomeFragment : Fragment() {
} }
binding.tabButton.setOnClickListener { binding.tabButton.setOnClickListener {
if (FeatureFlags.showStartOnHomeSettings) { requireComponents.analytics.metrics.track(Event.StartOnHomeOpenTabsTray)
requireComponents.analytics.metrics.track(Event.StartOnHomeOpenTabsTray)
}
openTabsTray() openTabsTray()
} }

@ -5,10 +5,9 @@
package org.mozilla.fenix.settings package org.mozilla.fenix.settings
import android.os.Bundle import android.os.Bundle
import androidx.preference.CheckBoxPreference
import androidx.navigation.findNavController import androidx.navigation.findNavController
import androidx.preference.CheckBoxPreference
import androidx.preference.Preference import androidx.preference.Preference
import androidx.preference.PreferenceCategory
import androidx.preference.PreferenceFragmentCompat import androidx.preference.PreferenceFragmentCompat
import androidx.preference.SwitchPreference import androidx.preference.SwitchPreference
import org.mozilla.fenix.FeatureFlags import org.mozilla.fenix.FeatureFlags
@ -87,9 +86,6 @@ class HomeSettingsFragment : PreferenceFragmentCompat() {
isVisible = FeatureFlags.showWallpapers isVisible = FeatureFlags.showWallpapers
} }
requirePreference<PreferenceCategory>(R.string.pref_key_start_on_home_category).isVisible =
FeatureFlags.showStartOnHomeSettings
addToRadioGroup( addToRadioGroup(
openingScreenRadioHomepage, openingScreenRadioHomepage,
openingScreenLastTab, openingScreenLastTab,

@ -264,7 +264,6 @@
<string name="pref_key_start_on_home_after_four_hours" translatable="false">pref_key_start_on_home_after_four_hours</string> <string name="pref_key_start_on_home_after_four_hours" translatable="false">pref_key_start_on_home_after_four_hours</string>
<string name="pref_key_start_on_home_always" translatable="false">pref_key_start_on_home_always</string> <string name="pref_key_start_on_home_always" translatable="false">pref_key_start_on_home_always</string>
<string name="pref_key_start_on_home_never" translatable="false">pref_key_start_on_home_never</string> <string name="pref_key_start_on_home_never" translatable="false">pref_key_start_on_home_never</string>
<string name="pref_key_start_on_home_category" translatable="false">pref_key_start_on_home_category</string>
<string name="pref_key_camera_permissions_needed" translatable="false">pref_key_camera_permissions_needed</string> <string name="pref_key_camera_permissions_needed" translatable="false">pref_key_camera_permissions_needed</string>
<string name="pref_key_inactive_tabs_category" translatable="false">pref_key_inactive_tabs_category</string> <string name="pref_key_inactive_tabs_category" translatable="false">pref_key_inactive_tabs_category</string>
<string name="pref_key_inactive_tabs" translatable="false">pref_key_inactive_tabs</string> <string name="pref_key_inactive_tabs" translatable="false">pref_key_inactive_tabs</string>

@ -45,8 +45,6 @@
android:layout="@layout/preference_cat_style" android:layout="@layout/preference_cat_style"
android:title="@string/preferences_opening_screen" android:title="@string/preferences_opening_screen"
app:allowDividerAbove="true" app:allowDividerAbove="true"
app:isPreferenceVisible="false"
android:key="pref_key_start_on_home_category"
app:iconSpaceReserved="false"> app:iconSpaceReserved="false">
<org.mozilla.fenix.settings.RadioButtonPreference <org.mozilla.fenix.settings.RadioButtonPreference

Loading…
Cancel
Save