mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager
synced 2024-09-06 17:14:02 +00:00
cli: enable TAB-completion for proxy properties in interactive editor
This commit is contained in:
parent
1abee2e0d5
commit
6397ce1fac
|
@ -5657,6 +5657,8 @@ should_complete_files (const char *prompt, const char *line)
|
|||
"phase2-private-key",
|
||||
/* 'team' and 'team-port' properties */
|
||||
"config",
|
||||
/* 'proxy' properties */
|
||||
"pac-script",
|
||||
NULL
|
||||
};
|
||||
return _get_and_check_property (prompt, line, file_properties, NULL, NULL);
|
||||
|
|
|
@ -2354,6 +2354,18 @@ nmc_property_proxy_set_method (NMSetting *setting, const char *prop,
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
static const char **
|
||||
nmc_property_proxy_allowed_method (NMSetting *setting, const char *prop)
|
||||
{
|
||||
static const char **words = NULL;
|
||||
|
||||
if (!words)
|
||||
words = nm_utils_enum_get_values (nm_setting_proxy_method_get_type(),
|
||||
NM_SETTING_PROXY_METHOD_NONE,
|
||||
G_MAXINT);
|
||||
return words;
|
||||
}
|
||||
|
||||
static gboolean
|
||||
nmc_property_proxy_set_pac_script (NMSetting *setting, const char *prop,
|
||||
const char *val, GError **error)
|
||||
|
@ -8155,7 +8167,7 @@ nmc_properties_init (void)
|
|||
nmc_property_proxy_set_method,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
nmc_property_proxy_allowed_method,
|
||||
NULL);
|
||||
nmc_add_prop_funcs (GLUE (PROXY, BROWSER_ONLY),
|
||||
nmc_property_proxy_get_browser_only,
|
||||
|
|
Loading…
Reference in a new issue