tUse accessor function - vaccinewars - be a doctor and try to vaccinate the world
(HTM) git clone git://src.adamsgaard.dk/vaccinewars
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) README
(DIR) LICENSE
---
(DIR) commit 630dd6f4c0a977f3f8a218ba223382addc0035ce
(DIR) parent 034e3c76f9d856e3a60da54d38aef27b172af88d
(HTM) Author: Ben Webb <ben@salilab.org>
Date: Sun, 15 Nov 2020 22:03:25 -0800
Use accessor function
Direct access to GTK+ object fields is discouraged
in GTK+2 and removed entirely in GTK+3; use accessor
function instead.
Diffstat:
M src/gui_client/gtk_client.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
(DIR) diff --git a/src/gui_client/gtk_client.c b/src/gui_client/gtk_client.c
t@@ -290,7 +290,7 @@ void ToggleSound(GtkWidget *widget, gpointer data)
widget = gtk_item_factory_get_widget(ClientData.Menu,
"<main>/Game/Enable sound");
if (widget) {
- enable = GTK_CHECK_MENU_ITEM(widget)->active;
+ enable = gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM(widget));
SoundEnable(enable);
}
}