[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
gEDA-cvs: CVS update: defines.h
User: cnieves
Date: 05/11/26 19:15:06
Modified: . defines.h funcs.h struct.h
Log:
Libgeda checks if there is an autosave backup file when loading a new
schematic and call an app-dependant function to ask the user what to do.
Gschem opens a window to ask the user. Other apps just output a warning
and continue.
Revision Changes Path
1.51 +3 -0 eda/geda/devel/libgeda/include/defines.h
(In the diff below, changes in quantity of whitespace are not shown.)
Index: defines.h
===================================================================
RCS file: /home/cvspsrv/cvsroot/eda/geda/devel/libgeda/include/defines.h,v
retrieving revision 1.50
retrieving revision 1.51
diff -u -b -r1.50 -r1.51
--- defines.h 28 Oct 2005 22:26:33 -0000 1.50
+++ defines.h 27 Nov 2005 00:15:04 -0000 1.51
@@ -387,3 +387,6 @@
#endif /* !__GNUC__ */
#endif
+
+/* Backup filename creation string */
+#define AUTOSAVE_BACKUP_FILENAME_STRING "#%s#"
1.7 +4 -0 eda/geda/devel/libgeda/include/funcs.h
(In the diff below, changes in quantity of whitespace are not shown.)
Index: funcs.h
===================================================================
RCS file: /home/cvspsrv/cvsroot/eda/geda/devel/libgeda/include/funcs.h,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -b -r1.6 -r1.7
--- funcs.h 19 Feb 2005 23:27:30 -0000 1.6
+++ funcs.h 27 Nov 2005 00:15:05 -0000 1.7
@@ -17,3 +17,7 @@
extern char * (*ps_color_string)();
extern int (*image_color_int)();
extern int (*image_gdcolor_init)();
+/* load_newer_backup_func is called if an autosave backup file is found
+ when loading a new schematic. It should ask the user what to do, and
+ return TRUE if the backup file should be loaded, or FALSE otherwise */
+extern int (*load_newer_backup_func)();
1.79 +4 -0 eda/geda/devel/libgeda/include/struct.h
(In the diff below, changes in quantity of whitespace are not shown.)
Index: struct.h
===================================================================
RCS file: /home/cvspsrv/cvsroot/eda/geda/devel/libgeda/include/struct.h,v
retrieving revision 1.78
retrieving revision 1.79
diff -u -b -r1.78 -r1.79
--- struct.h 18 Nov 2005 20:31:49 -0000 1.78
+++ struct.h 27 Nov 2005 00:15:05 -0000 1.79
@@ -399,6 +399,9 @@
gint ops_since_last_backup;
gchar do_autosave_backup;
+ /* Function which asks the user wether to load a newer backup file */
+ int (*load_newer_backup_func)();
+
/* left to right movement */
PAGE *prev;
PAGE *next;
@@ -439,6 +442,7 @@
/* this points to the owner of this filedialog structure */
/* should NEVER be freed */
TOPLEVEL *toplevel;
+
};
struct st_toplevel {