summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorvelsinki <112010-velsinki@users.noreply.gitlab.gnome.org>2023-03-30 00:44:43 +0200
committerFelipe Borges <felipeborges@gnome.org>2023-04-03 11:17:05 +0200
commitaa7a6b09411d4d179757b40a62cf89d40fcdec53 (patch)
treedbdaf69039d36f9c78386c4cf029a85bf3837626
parenteb0bdd5a93a06308e2259868dfd39554895cc455 (diff)
downloadgnome-control-center-aa7a6b09411d4d179757b40a62cf89d40fcdec53.tar.gz
sharing: Fix network row visible name bug
In `cc_sharing_networks_new_row`, the `network_name` is not being set to the new row, but to `self->current_row`. This is incorrect behavior, as it leaves the new row without any title, and overwrites the title of the current row incorrectly to the last network entry in the enabled networks list. This fix correctly sets the name to the new row instead. This problem is at least discussed in #2318 (point 3) and causes some confusion in #2299 as well.
-rw-r--r--panels/sharing/cc-sharing-networks.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/panels/sharing/cc-sharing-networks.c b/panels/sharing/cc-sharing-networks.c
index 56b38a212..bffaf6ea1 100644
--- a/panels/sharing/cc-sharing-networks.c
+++ b/panels/sharing/cc-sharing-networks.c
@@ -213,7 +213,7 @@ cc_sharing_networks_new_row (const char *uuid,
}
adw_action_row_set_icon_name (ADW_ACTION_ROW (row), icon_name);
- adw_preferences_row_set_title (ADW_PREFERENCES_ROW (self->current_row), network_name);
+ adw_preferences_row_set_title (ADW_PREFERENCES_ROW (row), network_name);
/* Remove button */
w = gtk_button_new_from_icon_name ("window-close-symbolic");