dia r4159 - in trunk: . app



Author: hans
Date: Thu Dec 18 22:39:10 2008
New Revision: 4159
URL: http://svn.gnome.org/viewvc/dia?rev=4159&view=rev

Log:
2008-12-18  Hans Breuer  <hans breuer org>

	* app/properties.[ch] : renamed to properties-dialog.* to have unique
	filenames (avoids debugger confusion)
	* app/Makefile.am app/makefile.msc app/makefile.mingw
	  app/commands.c app/defaults.c app/diagram.c app/diagram_tree.c
	  app/modify_tool.c : adapted accordingly

	* app/properties-dialog.c : restored nullification of the static 
	'object_part' on dialog destroy to avoid double destruction



Added:
   trunk/app/properties-dialog.c
      - copied, changed from r4153, /trunk/app/properties.c
   trunk/app/properties-dialog.h
      - copied unchanged from r4153, /trunk/app/properties.h
Removed:
   trunk/app/properties.c
   trunk/app/properties.h
Modified:
   trunk/ChangeLog
   trunk/app/Makefile.am
   trunk/app/commands.c
   trunk/app/defaults.c
   trunk/app/diagram.c
   trunk/app/diagram_tree.c
   trunk/app/makefile.mingw
   trunk/app/makefile.msc
   trunk/app/modify_tool.c
   trunk/app/undo.c

Modified: trunk/app/Makefile.am
==============================================================================
--- trunk/app/Makefile.am	(original)
+++ trunk/app/Makefile.am	Thu Dec 18 22:39:10 2008
@@ -91,8 +91,8 @@
 	    preferences.h \
 	    load_save.c \
 	    load_save.h \
-	    properties.c \
-	    properties.h \
+	    properties-dialog.c \
+	    properties-dialog.h \
 	    defaults.c \
 	    defaults.h \
 	    undo.c \

Modified: trunk/app/commands.c
==============================================================================
--- trunk/app/commands.c	(original)
+++ trunk/app/commands.c	Thu Dec 18 22:39:10 2008
@@ -69,7 +69,7 @@
 #include "utils.h"
 #include "message.h"
 #include "grid.h"
-#include "properties.h"
+#include "properties-dialog.h"
 #include "propinternals.h"
 #include "preferences.h"
 #include "layer_dialog.h"
@@ -746,7 +746,7 @@
         "name", "Dia",
 	"version", VERSION,
 	"comments", _("A program for drawing structured diagrams."),
-	"copyright", "(C) 1998-2007 The Free Software Foundation and the authors",
+	"copyright", "(C) 1998-2008 The Free Software Foundation and the authors",
 	"website", "http://live.gnome.org/Dia";,
 	"authors", authors,
 	"documenters", documentors,

Modified: trunk/app/defaults.c
==============================================================================
--- trunk/app/defaults.c	(original)
+++ trunk/app/defaults.c	Thu Dec 18 22:39:10 2008
@@ -22,7 +22,7 @@
 
 #include "defaults.h"
 #include "intl.h"
-#include "properties.h"
+#include "properties-dialog.h"
 #include "object_ops.h"
 #include "connectionpoint_ops.h"
 #include "object.h"

Modified: trunk/app/diagram.c
==============================================================================
--- trunk/app/diagram.c	(original)
+++ trunk/app/diagram.c	Thu Dec 18 22:39:10 2008
@@ -30,7 +30,7 @@
 #include "message.h"
 #include "menus.h"
 #include "preferences.h"
-#include "properties.h"
+#include "properties-dialog.h"
 #include "cut_n_paste.h"
 #include "layer_dialog.h"
 #include "app_procs.h"

Modified: trunk/app/diagram_tree.c
==============================================================================
--- trunk/app/diagram_tree.c	(original)
+++ trunk/app/diagram_tree.c	Thu Dec 18 22:39:10 2008
@@ -27,7 +27,7 @@
 
 #undef GTK_DISABLE_DEPRECATED /* GtkCTree */
 
-#include "properties.h"
+#include "properties-dialog.h"
 #include "diagram_tree_menu.h"
 #include "diagram_tree_menu_callbacks.h"
 #include "diagram_tree.h"

Modified: trunk/app/makefile.mingw
==============================================================================
--- trunk/app/makefile.mingw	(original)
+++ trunk/app/makefile.mingw	Thu Dec 18 22:39:10 2008
@@ -67,7 +67,7 @@
 	paginate_psprint.o \
 	plugin-manager.o \
 	preferences.o \
-	properties.o \
+	properties-dialog.o \
 	recent_files.o \
 	render_eps.o \
 	render_gdk.o \

Modified: trunk/app/makefile.msc
==============================================================================
--- trunk/app/makefile.msc	(original)
+++ trunk/app/makefile.msc	Thu Dec 18 22:39:10 2008
@@ -61,7 +61,7 @@
 	pagesetup.obj \
 	plugin-manager.obj \
 	preferences.obj \
-	properties.obj \
+	properties-dialog.obj \
 	recent_files.obj \
 	render_gdk.obj \
 	scroll_tool.obj \

Modified: trunk/app/modify_tool.c
==============================================================================
--- trunk/app/modify_tool.c	(original)
+++ trunk/app/modify_tool.c	Thu Dec 18 22:39:10 2008
@@ -25,7 +25,7 @@
 #include "object_ops.h"
 #include "connectionpoint_ops.h"
 #include "message.h"
-#include "properties.h"
+#include "properties-dialog.h"
 #include "select.h"
 #include "preferences.h"
 #include "cursor.h"

Copied: trunk/app/properties-dialog.c (from r4153, /trunk/app/properties.c)
==============================================================================
--- /trunk/app/properties.c	(original)
+++ trunk/app/properties-dialog.c	Thu Dec 18 22:39:10 2008
@@ -24,7 +24,7 @@
 #include <gdk/gdkkeysyms.h>
 
 #include "intl.h"
-#include "properties.h"
+#include "properties-dialog.h"
 #include "object_ops.h"
 #include "connectionpoint_ops.h"
 #include "undo.h"
@@ -83,6 +83,18 @@
   g_object_ref_sink (G_OBJECT (no_properties_dialog));
 }
 
+/* when the dialog gets destroyed we need to drop our references */
+static gint
+properties_part_destroyed(GtkWidget *widget, gpointer data)
+{
+  if (widget == object_part) {
+    object_part = NULL;
+    current_objects = NULL;
+    current_dia = NULL;
+  }
+  return 0;
+}
+
 static gboolean
 properties_key_event(GtkWidget *widget, GdkEventKey *event, gpointer data)
 {
@@ -232,6 +244,8 @@
     gtk_window_set_title(GTK_WINDOW(dialog), _("Object properties:"));
   }
 
+  g_signal_connect (G_OBJECT (properties), "destroy",
+		  G_CALLBACK(properties_part_destroyed), NULL);
   gtk_box_pack_start(GTK_BOX(dialog_vbox), properties, TRUE, TRUE, 0);
 
   gtk_widget_show (properties);

Modified: trunk/app/undo.c
==============================================================================
--- trunk/app/undo.c	(original)
+++ trunk/app/undo.c	Thu Dec 18 22:39:10 2008
@@ -20,7 +20,7 @@
 
 #include "undo.h"
 #include "object_ops.h"
-#include "properties.h"
+#include "properties-dialog.h"
 #include "connectionpoint_ops.h"
 #include "focus.h"
 #include "group.h"



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]