nmtui: fix WireGuard peer editor empty fields

Previously, input fields for peer attributes such as 'Public Key' were
not pre-populated with the existing settings of the peer. This was due
to the WireGuard peer editor class not setting its peer property during
object construction, as the necessary flag was absent. This commit
addresses and fixes this issue.

Closes #1443

https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/merge_requests/1851
This commit is contained in:
Javier Sánchez Parra
2024-01-29 10:38:38 +01:00
committed by Fernando Fernandez Mancera
parent 0607340922
commit 7e7d3a7981

View File

@@ -237,11 +237,12 @@ nmt_wireguard_peer_editor_class_init(NmtWireguardPeerEditorClass *peer_class)
*
* The page's #NMWireGuardPeer.
*/
g_object_class_install_property(object_class,
g_object_class_install_property(
object_class,
PROP_PEER,
g_param_spec_boxed("peer",
"",
"",
nm_wireguard_peer_get_type(),
G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
G_PARAM_READWRITE | G_PARAM_CONSTRUCT | G_PARAM_STATIC_STRINGS));
}