sharing: Fix warning when disabling sharing
The warning is: (gnome-control-center:29760): Gtk-CRITICAL **: 11:45:48.076: gtk_widget_is_visible: assertion 'GTK_IS_WIDGET (widget)' failed This is due to the code trying to disable switches that only exist if support for that feature is available.
This commit is contained in:
parent
b47ada9b76
commit
a57a85a1db
1 changed files with 1 additions and 1 deletions
|
@ -109,7 +109,7 @@ struct _CcSharingPanel
|
|||
|
||||
CC_PANEL_REGISTER (CcSharingPanel, cc_sharing_panel)
|
||||
|
||||
#define OFF_IF_VISIBLE(x, y) { if (gtk_widget_is_visible(x) && gtk_widget_is_sensitive(y)) gtk_switch_set_active (GTK_SWITCH(y), FALSE); }
|
||||
#define OFF_IF_VISIBLE(x, y) { if (gtk_widget_is_visible(x) && (y) != NULL && gtk_widget_is_sensitive(y)) gtk_switch_set_active (GTK_SWITCH(y), FALSE); }
|
||||
|
||||
static void
|
||||
cc_sharing_panel_master_switch_notify (GtkSwitch *gtkswitch,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue