From edcf067266e19fd382c367bb54567bf2c2d8aac9 Mon Sep 17 00:00:00 2001 From: Dan Winship Date: Tue, 30 Sep 2014 07:48:06 -0400 Subject: [PATCH] tui: clarify the "Device" widget with PPPoE connections (rh #1105753) PPPoE connections involve two different network connections, making it ambiguous what the "Device" field refers to. Clarify that it refers to the Ethernet device, not the PPP device. --- clients/tui/nmt-page-main.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/clients/tui/nmt-page-main.c b/clients/tui/nmt-page-main.c index 045150e1ab..93d07dbc6a 100644 --- a/clients/tui/nmt-page-main.c +++ b/clients/tui/nmt-page-main.c @@ -171,6 +171,7 @@ nmt_page_main_constructed (GObject *object) NMConnection *conn; NMSettingConnection *s_con; NmtNewtWidget *widget, *section, *separator; + const char *deventry_label; NmtDeviceEntry *deventry; GType hardware_type; const char *slave_type; @@ -191,7 +192,15 @@ nmt_page_main_constructed (GObject *object) else hardware_type = priv->type_data->device_type; - widget = nmt_device_entry_new (_("Device"), 40, hardware_type); + /* For connections involving multiple network devices, clarify which one + * NMSettingConnection:interface-name refers to. + */ + if (nm_connection_is_type (conn, NM_SETTING_PPPOE_SETTING_NAME)) + deventry_label = _("Ethernet device"); + else + deventry_label = _("Device"); + + widget = nmt_device_entry_new (deventry_label, 40, hardware_type); nmt_page_grid_append (grid, NULL, widget, NULL); deventry = NMT_DEVICE_ENTRY (widget); g_object_bind_property (s_con, NM_SETTING_CONNECTION_INTERFACE_NAME,