1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105
|
// Copyright 2014 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef COMPONENTS_SEARCH_ENGINES_SEARCH_ENGINES_SWITCHES_H_
#define COMPONENTS_SEARCH_ENGINES_SEARCH_ENGINES_SWITCHES_H_
#include <string>
#include "base/component_export.h"
#include "base/feature_list.h"
#include "base/metrics/field_trial_params.h"
#include "build/build_config.h"
namespace switches {
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
extern const char kExtraSearchQueryParams[];
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
extern const char kIgnoreNoFirstRunForSearchEngineChoiceScreen[];
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
extern const char kDisableSearchEngineChoiceScreen[];
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
extern const char kForceSearchEngineChoiceScreen[];
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
BASE_DECLARE_FEATURE(kInvalidateSearchEngineChoiceOnDeviceRestoreDetection);
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
extern const base::FeatureParam<bool> kInvalidateChoiceOnRestoreIsRetroactive;
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
BASE_DECLARE_FEATURE(kSearchEngineChoiceTrigger);
#if BUILDFLAG(IS_ANDROID)
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
BASE_DECLARE_FEATURE(kRemoveSearchEngineChoiceAttribution);
#endif
// The string that's passed to
// `switches::kSearchEngineChoiceTriggerRepromptParams` so that we don't
// reprompt users with the choice screen.
inline constexpr char kSearchEngineChoiceNoRepromptString[] = "NO_REPROMPT";
// Reprompt params for the search engine choice.
// This is a JSON dictionary where keys are country codes, and values are Chrome
// version strings. The wildcard country '*' represents all countries.
// When a specific country is specified, it takes precedence over the wildcard.
//
// Example: {"*": "2.0.0.0", "BE": "5.0.0.0"}
// This reprompts users in Belgium who made the choice strictly before version
// 5, and users in all other countries who made the choice strictly before
// version 2.
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
extern const base::FeatureParam<std::string>
kSearchEngineChoiceTriggerRepromptParams;
#if BUILDFLAG(IS_IOS)
// Maximum number of time the search engine choice screen can be skipped
// because the application is started via an external intent. Once this
// count is reached, the search engine choice screen is presented on all
// restart until the user has made a decision.
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
extern const base::FeatureParam<int> kSearchEngineChoiceMaximumSkipCount;
#endif
#if BUILDFLAG(IS_ANDROID)
// Enables the blocking dialog that directs users to complete their choice of
// default apps (for Browser & Search) in Android.
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
BASE_DECLARE_FEATURE(kClayBlocking);
// Enables the alternative behaviour for the connection to the default apps
// choice internal backend in Android.
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
BASE_DECLARE_FEATURE(kClayBackendConnectionV2);
// Enables showing a snackbar when users change their default search engine in
// Android.
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
BASE_DECLARE_FEATURE(kClaySnackbar);
#endif
// Kill switch to revert the fix of using assistedQueryStats for prefetch source
// component. See crbug.com/345275145.
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
BASE_DECLARE_FEATURE(kPrefetchParameterFix);
// Kill switch to revert the fix of dropping searchbox stats (gs_lcrp) from
// prefetch requests. See crbug.com/350939001.
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
BASE_DECLARE_FEATURE(kRemoveSearchboxStatsParamFromPrefetchRequests);
// Switch guarding TemplateURL syncing of untouched autogenerated search
// engines.
COMPONENT_EXPORT(SEARCH_ENGINES_SWITCHES)
BASE_DECLARE_FEATURE(kDisableSyncAutogeneratedSearchEngines);
} // namespace switches
#endif // COMPONENTS_SEARCH_ENGINES_SEARCH_ENGINES_SWITCHES_H_
|