Complete.Org: Mailing Lists: Archives: freeciv-dev: April 2005:
[Freeciv-Dev] Re: (PR#12761) remove make_modal parameter of popup_city_d
Home

[Freeciv-Dev] Re: (PR#12761) remove make_modal parameter of popup_city_d

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
Subject: [Freeciv-Dev] Re: (PR#12761) remove make_modal parameter of popup_city_dialog
From: "Jason Short" <jdorje@xxxxxxxxxxxxxxxxxxxxx>
Date: Sun, 10 Apr 2005 10:49:02 -0700
Reply-to: bugs@xxxxxxxxxxx

<URL: http://bugs.freeciv.org/Ticket/Display.html?id=12761 >

Jason Short wrote:
> <URL: http://bugs.freeciv.org/Ticket/Display.html?id=12761 >
> 
> This patch removes the make_modal parameter of the popup_city_dialog 
> function.

Oops.  That patch had garbage in it.  This one removes it (otherwise 
identical).

-jason

Index: client/control.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/control.c,v
retrieving revision 1.167
diff -u -r1.167 control.c
--- client/control.c    6 Apr 2005 21:24:41 -0000       1.167
+++ client/control.c    10 Apr 2005 17:47:53 -0000
@@ -1471,7 +1471,7 @@
   }
   /* Otherwise use popups. */
   else if (pcity && can_player_see_city_internals(game.player_ptr, pcity)) {
-    popup_city_dialog(pcity, FALSE);
+    popup_city_dialog(pcity);
   }
   else if (unit_list_size(ptile->units) == 0 && !pcity
            && punit_focus) {
Index: client/messagewin_common.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/messagewin_common.c,v
retrieving revision 1.20
diff -u -r1.20 messagewin_common.c
--- client/messagewin_common.c  28 Mar 2005 17:05:54 -0000      1.20
+++ client/messagewin_common.c  10 Apr 2005 17:47:53 -0000
@@ -199,7 +199,7 @@
        *
        * In both cases, it would be better if the popup button weren't
        * highlighted at all - this is left up to the GUI. */
-      popup_city_dialog(pcity, FALSE);
+      popup_city_dialog(pcity);
     }
   }
 }
Index: client/packhand.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/packhand.c,v
retrieving revision 1.486
diff -u -r1.486 packhand.c
--- client/packhand.c   1 Apr 2005 00:05:59 -0000       1.486
+++ client/packhand.c   10 Apr 2005 17:47:53 -0000
@@ -603,7 +603,7 @@
       (!game.player_ptr->ai.control)) {
     update_menus();
     if (!city_dialog_is_open(pcity)) {
-      popup_city_dialog(pcity, FALSE);
+      popup_city_dialog(pcity);
     }
   }
 
Index: client/gui-gtk-2.0/citydlg.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/gui-gtk-2.0/citydlg.c,v
retrieving revision 1.124
diff -u -r1.124 citydlg.c
--- client/gui-gtk-2.0/citydlg.c        10 Apr 2005 01:59:31 -0000      1.124
+++ client/gui-gtk-2.0/citydlg.c        10 Apr 2005 17:47:54 -0000
@@ -169,8 +169,6 @@
   Impr_Type_id sell_id;
 
   int cwidth;
-
-  bool is_modal;
 };
 
 static GtkRcStyle *info_label_style[NUM_INFO_STYLES] = { NULL, NULL, NULL };
@@ -198,8 +196,7 @@
 static void create_and_append_cma_page(struct city_dialog *pdialog);
 static void create_and_append_settings_page(struct city_dialog *pdialog);
 
-static struct city_dialog *create_city_dialog(struct city *pcity,
-                                             bool make_modal);
+static struct city_dialog *create_city_dialog(struct city *pcity);
 
 static void city_dialog_update_title(struct city_dialog *pdialog);
 static void city_dialog_update_citizens(struct city_dialog *pdialog);
@@ -423,12 +420,12 @@
 /****************************************************************
 popup the dialog 10% inside the main-window 
 *****************************************************************/
-void popup_city_dialog(struct city *pcity, bool make_modal)
+void popup_city_dialog(struct city *pcity)
 {
   struct city_dialog *pdialog;
 
   if (!(pdialog = get_city_dialog(pcity))) {
-    pdialog = create_city_dialog(pcity, make_modal);
+    pdialog = create_city_dialog(pcity);
   }
 
   gtk_window_present(GTK_WINDOW(pdialog->shell));
@@ -1184,8 +1181,7 @@
 /****************************************************************
 ...
 *****************************************************************/
-static struct city_dialog *create_city_dialog(struct city *pcity,
-                                             bool make_modal)
+static struct city_dialog *create_city_dialog(struct city *pcity)
 {
   struct city_dialog *pdialog;
 
@@ -1325,8 +1321,6 @@
   /* need to do this every time a new dialog is opened. */
   city_dialog_update_prev_next();
 
-  pdialog->is_modal = make_modal;
-
   gtk_widget_show_all(GTK_DIALOG(pdialog->shell)->vbox);
   gtk_widget_show_all(GTK_DIALOG(pdialog->shell)->action_area);
 
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.71
diff -u -r1.71 cityrep.c
--- client/gui-gtk-2.0/cityrep.c        10 Apr 2005 03:31:22 -0000      1.71
+++ client/gui-gtk-2.0/cityrep.c        10 Apr 2005 17:47:54 -0000
@@ -1028,7 +1028,7 @@
     center_tile_mapcanvas(pcity->tile);
   }
 
-  popup_city_dialog(pcity, 0);
+  popup_city_dialog(pcity);
 }
 
 /****************************************************************
Index: client/gui-gtk-2.0/dialogs.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/gui-gtk-2.0/dialogs.c,v
retrieving revision 1.98
diff -u -r1.98 dialogs.c
--- client/gui-gtk-2.0/dialogs.c        28 Mar 2005 16:59:14 -0000      1.98
+++ client/gui-gtk-2.0/dialogs.c        10 Apr 2005 17:47:54 -0000
@@ -186,7 +186,7 @@
     }
 
     if (pcity) {
-      popup_city_dialog(pcity, 0);
+      popup_city_dialog(pcity);
     }
     break;
   }
Index: client/include/citydlg_g.h
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/include/citydlg_g.h,v
retrieving revision 1.7
diff -u -r1.7 citydlg_g.h
--- client/include/citydlg_g.h  3 Sep 2004 04:22:36 -0000       1.7
+++ client/include/citydlg_g.h  10 Apr 2005 17:47:54 -0000
@@ -17,7 +17,7 @@
 
 #include "citydlg_common.h"
 
-void popup_city_dialog(struct city *pcity, bool make_modal);
+void popup_city_dialog(struct city *pcity);
 void popdown_city_dialog(struct city *pcity);
 void popdown_all_city_dialogs(void);
 void refresh_city_dialog(struct city *pcity);

[Prev in Thread] Current Thread [Next in Thread]
  • [Freeciv-Dev] Re: (PR#12761) remove make_modal parameter of popup_city_dialog, Jason Short <=