Project

General

Profile

Bug #2034 » 0041-gtk4-x-Fix-trading-cities.patch

main - Marko Lindqvist, 05/21/2026 04:34 AM

View differences:

client/gui-gtk-4.0/diplodlg.c
for (j = 0; j < i; j++) {
struct city_deal *deal = fc_malloc(sizeof(struct city_deal));
fc_snprintf(act_name, sizeof(act_name), "city%s%d", act_plr_part, i);
fc_snprintf(act_name, sizeof(act_name), "city%s%d", act_plr_part, j);
act = g_simple_action_new(act_name, NULL);
deal->giver = player_number(pgiver);
......
(gpointer)deal);
fc_snprintf(act_name, sizeof(act_name), "win.city%s%d",
act_plr_part, i);
act_plr_part, j);
menu_item_append_unref(submenu,
g_menu_item_new(city_name_get(city_list_ptrs[j]),
act_name));
client/gui-gtk-5.0/diplodlg.c
for (j = 0; j < i; j++) {
struct city_deal *deal = fc_malloc(sizeof(struct city_deal));
fc_snprintf(act_name, sizeof(act_name), "city%s%d", act_plr_part, i);
fc_snprintf(act_name, sizeof(act_name), "city%s%d", act_plr_part, j);
act = g_simple_action_new(act_name, NULL);
deal->giver = player_number(pgiver);
......
(gpointer)deal);
fc_snprintf(act_name, sizeof(act_name), "win.city%s%d",
act_plr_part, i);
act_plr_part, j);
menu_item_append_unref(submenu,
g_menu_item_new(city_name_get(city_list_ptrs[j]),
act_name));
(2-2/3)