mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
chore: remove unused commandLineSwitches flag (#49993)
chore: remove unused commandLineSwitches flag
This commit is contained in:
@@ -135,7 +135,6 @@ void WebContentsPreferences::Clear() {
|
||||
default_encoding_ = std::nullopt;
|
||||
is_webview_ = false;
|
||||
custom_args_.clear();
|
||||
custom_switches_.clear();
|
||||
enable_blink_features_ = std::nullopt;
|
||||
disable_blink_features_ = std::nullopt;
|
||||
disable_popups_ = false;
|
||||
@@ -204,7 +203,6 @@ void WebContentsPreferences::SetFromDictionary(
|
||||
if (web_preferences.Get("defaultEncoding", &encoding))
|
||||
default_encoding_ = encoding;
|
||||
web_preferences.Get(options::kCustomArgs, &custom_args_);
|
||||
web_preferences.Get("commandLineSwitches", &custom_switches_);
|
||||
web_preferences.Get("disablePopups", &disable_popups_);
|
||||
web_preferences.Get("disableDialogs", &disable_dialogs_);
|
||||
web_preferences.Get("safeDialogs", &safe_dialogs_);
|
||||
@@ -338,11 +336,6 @@ void WebContentsPreferences::AppendCommandLineSwitches(
|
||||
if (!arg.empty())
|
||||
command_line->AppendArg(arg);
|
||||
|
||||
// Custom command line switches.
|
||||
for (const auto& arg : custom_switches_)
|
||||
if (!arg.empty())
|
||||
command_line->AppendSwitch(arg);
|
||||
|
||||
if (enable_blink_features_)
|
||||
command_line->AppendSwitchASCII(::switches::kEnableBlinkFeatures,
|
||||
*enable_blink_features_);
|
||||
|
||||
@@ -122,7 +122,6 @@ class WebContentsPreferences
|
||||
std::optional<std::string> default_encoding_;
|
||||
bool is_webview_;
|
||||
std::vector<std::string> custom_args_;
|
||||
std::vector<std::string> custom_switches_;
|
||||
std::optional<std::string> enable_blink_features_;
|
||||
std::optional<std::string> disable_blink_features_;
|
||||
bool disable_popups_;
|
||||
|
||||
Reference in New Issue
Block a user