[Freeciv-Dev] (PR#5801) i18n: activeunits dialog buttons in russian (GTK
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
<URL: http://rt.freeciv.org/Ticket/Display.html?id=5801 >
> [vasc - Thu Apr 01 00:28:18 2004]:
>
> Since GTK+ 1.2 does not have the refresh buttons (they were mainly used
> in the ye olde days for AI debugging), I propose we nuke the Refresh
> buttons from the report dialogs.
This patch removes the refresh buttons from the cities and units reports.
Index: client/gui-gtk-2.0/cityrep.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/gui-gtk-2.0/cityrep.c,v
retrieving revision 1.58
diff -u -r1.58 cityrep.c
--- client/gui-gtk-2.0/cityrep.c 1 May 2004 17:28:47 -0000 1.58
+++ client/gui-gtk-2.0/cityrep.c 18 Sep 2004 23:23:47 -0000
@@ -67,7 +67,6 @@
GtkTreeViewColumn *col, gpointer data);
static void city_buy_callback(GtkWidget *w, gpointer data);
-static void city_refresh_callback(GtkWidget *w, gpointer data);
static void city_selection_changed_callback(GtkTreeSelection *selection);
static void create_select_menu(GtkWidget *item);
@@ -824,11 +823,6 @@
g_signal_connect(w, "clicked", G_CALLBACK(city_buy_callback), NULL);
city_buy_command = w;
- w = gtk_stockbutton_new(GTK_STOCK_REFRESH, _("_Refresh"));
- gtk_box_pack_end(GTK_BOX(GTK_DIALOG(city_dialog_shell)->action_area),
- w, FALSE, TRUE, 0);
- g_signal_connect(w, "clicked", G_CALLBACK(city_refresh_callback), NULL);
-
gtk_dialog_add_button(GTK_DIALOG(city_dialog_shell),
GTK_STOCK_CLOSE, GTK_RESPONSE_CLOSE);
@@ -1005,36 +999,6 @@
/****************************************************************
...
*****************************************************************/
-static void refresh_iterate(GtkTreeModel *model, GtkTreePath *path,
- GtkTreeIter *it, gpointer data)
-{
- gint id;
-
- *(gboolean *)data = TRUE;
- gtk_tree_model_get(model, it, 1, &id, -1);
-
- dsend_packet_city_refresh(&aconnection, id);
-}
-
-/****************************************************************
-...
-*****************************************************************/
-static void city_refresh_callback(GtkWidget * w, gpointer data)
-{
- /* added by Syela - I find this very useful */
- gboolean found = FALSE;
-
- gtk_tree_selection_selected_foreach(city_selection, refresh_iterate,
- &found);
-
- if (!found) {
- dsend_packet_city_refresh(&aconnection, 0);
- }
-}
-
-/****************************************************************
-...
-*****************************************************************/
static void buy_iterate(GtkTreeModel *model, GtkTreePath *path,
GtkTreeIter *it, gpointer data)
{
Index: client/gui-gtk-2.0/repodlgs.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/gui-gtk-2.0/repodlgs.c,v
retrieving revision 1.56
diff -u -r1.56 repodlgs.c
--- client/gui-gtk-2.0/repodlgs.c 14 Sep 2004 19:26:23 -0000 1.56
+++ client/gui-gtk-2.0/repodlgs.c 18 Sep 2004 23:23:50 -0000
@@ -100,7 +100,7 @@
static GtkTreeSelection *activeunits_selection;
enum {
- ACTIVEUNITS_NEAREST = 1, ACTIVEUNITS_UPGRADE, ACTIVEUNITS_REFRESH
+ ACTIVEUNITS_NEAREST = 1, ACTIVEUNITS_UPGRADE
};
static int activeunits_dialog_shell_is_modal;
@@ -1002,10 +1002,6 @@
gtk_dialog_set_response_sensitive(GTK_DIALOG(activeunits_dialog_shell),
ACTIVEUNITS_UPGRADE, FALSE);
- command = gtk_button_new_from_stock(GTK_STOCK_REFRESH);
- gtk_dialog_add_action_widget(GTK_DIALOG(activeunits_dialog_shell),
- command, ACTIVEUNITS_REFRESH);
-
gtk_dialog_add_button(GTK_DIALOG(activeunits_dialog_shell),
GTK_STOCK_CLOSE, GTK_RESPONSE_CLOSE);
@@ -1108,9 +1104,6 @@
case ACTIVEUNITS_NEAREST:
case ACTIVEUNITS_UPGRADE:
break;
- case ACTIVEUNITS_REFRESH:
- activeunits_report_dialog_update();
- return;
default:
gtk_widget_destroy(activeunits_dialog_shell);
return;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Freeciv-Dev] (PR#5801) i18n: activeunits dialog buttons in russian (GTK-2.0 client),
Vasco Alexandre da Silva Costa <=
|
|