From c390d4f36d53adeb197adef41259d2ed050bc229 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Wed, 25 May 2011 08:33:56 -0400 Subject: [PATCH] Network: use the correct condition for the option button The button needs a connection to edit; so set the sensitivity based on the existence of a connection. --- panels/network/cc-network-panel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/panels/network/cc-network-panel.c b/panels/network/cc-network-panel.c index 15c2950c0..9d4b1db8d 100644 --- a/panels/network/cc-network-panel.c +++ b/panels/network/cc-network-panel.c @@ -1270,7 +1270,7 @@ refresh_header_ui (CcNetworkPanel *panel, NMDevice *device, const char *page_nam widget = GTK_WIDGET (gtk_builder_get_object (panel->priv->builder, wid_name)); g_free (wid_name); if (widget != NULL) { - gtk_widget_set_sensitive (widget, state == NM_DEVICE_STATE_ACTIVATED); + gtk_widget_set_sensitive (widget, find_connection_for_device (panel, device) != NULL); } }