? debian
? doc/gtkhtml-undocumented.txt
? po/tmp
Index: src/gtkhtml-enums.h
===================================================================
RCS file: /cvs/gnome/gtkhtml/src/gtkhtml-enums.h,v
retrieving revision 1.32
diff -p -u -r1.32 gtkhtml-enums.h
--- src/gtkhtml-enums.h	16 Sep 2002 13:44:54 -0000	1.32
+++ src/gtkhtml-enums.h	26 Nov 2002 13:40:58 -0000
@@ -214,6 +214,9 @@ typedef enum {
 
 	GTK_HTML_COMMAND_SCROLL_BOD,
 	GTK_HTML_COMMAND_SCROLL_EOD,
+
+	GTK_HTML_COMMAND_AUTOSAVED,
+	GTK_HTML_COMMAND_IS_AUTOSAVED,
 } GtkHTMLCommandType;
 
 typedef enum {
Index: src/gtkhtml-properties.c
===================================================================
RCS file: /cvs/gnome/gtkhtml/src/gtkhtml-properties.c,v
retrieving revision 1.77
diff -p -u -r1.77 gtkhtml-properties.c
--- src/gtkhtml-properties.c	28 Aug 2002 21:53:27 -0000	1.77
+++ src/gtkhtml-properties.c	26 Nov 2002 13:40:59 -0000
@@ -561,6 +561,8 @@ static GtkEnumValue _gtk_html_command_va
   { GTK_HTML_COMMAND_IS_SAVED, "GTK_HTML_COMMAND_IS_SAVED", "is-saved" },
   { GTK_HTML_COMMAND_SCROLL_BOD, "GTK_HTML_COMMAND_SCROLL_BOD", "scroll-bod" },
   { GTK_HTML_COMMAND_SCROLL_EOD, "GTK_HTML_COMMAND_SCROLL_EOD", "scroll-eod" },
+  { GTK_HTML_COMMAND_AUTOSAVED, "GTK_HTML_COMMAND_AUTOSAVED", "autosaved" },
+  { GTK_HTML_COMMAND_IS_AUTOSAVED, "GTK_HTML_COMMAND_IS_AUTOSAVED", "is-autosaved" },
   { 0, NULL, NULL }
 };
 
Index: src/gtkhtml.c
===================================================================
RCS file: /cvs/gnome/gtkhtml/src/gtkhtml.c,v
retrieving revision 1.450.2.1
diff -p -u -r1.450.2.1 gtkhtml.c
--- src/gtkhtml.c	6 Nov 2002 20:36:56 -0000	1.450.2.1
+++ src/gtkhtml.c	26 Nov 2002 13:41:03 -0000
@@ -4383,6 +4383,12 @@ command (GtkHTML *html, GtkHTMLCommandTy
 	case GTK_HTML_COMMAND_IS_SAVED:
 		rv = html_engine_is_saved (html->engine);
 		break;
+	case GTK_HTML_COMMAND_AUTOSAVED:
+		html_engine_autosaved (html->engine);
+		break;
+	case GTK_HTML_COMMAND_IS_AUTOSAVED:
+		rv = html_engine_is_autosaved (html->engine);
+		break;
 	default:
 		html->binding_handled = FALSE;
 	}
Index: src/htmlengine.c
===================================================================
RCS file: /cvs/gnome/gtkhtml/src/htmlengine.c,v
retrieving revision 1.499
diff -p -u -r1.499 htmlengine.c
--- src/htmlengine.c	25 Oct 2002 16:37:07 -0000	1.499
+++ src/htmlengine.c	26 Nov 2002 13:41:05 -0000
@@ -3563,7 +3563,7 @@ html_engine_init (HTMLEngine *engine)
 
 	engine->block = FALSE;
 	engine->save_data = FALSE;
-	engine->saved_step_count = -1;
+	engine->saved_step_count = engine->autosaved_step_count = -1;
 
 	engine->map_table = NULL;
 }
@@ -5642,6 +5642,18 @@ void
 html_engine_saved (HTMLEngine *e)
 {
 	e->saved_step_count = html_undo_get_step_count (e->undo);
+}
+
+gboolean
+html_engine_is_autosaved (HTMLEngine *e)
+{
+	return e->autosaved_step_count != -1 && e->autosaved_step_count == html_undo_get_step_count (e->undo);
+}
+
+void
+html_engine_autosaved (HTMLEngine *e)
+{
+	e->autosaved_step_count = html_undo_get_step_count (e->undo);
 }
 
 static void
Index: src/htmlengine.h
===================================================================
RCS file: /cvs/gnome/gtkhtml/src/htmlengine.h,v
retrieving revision 1.159
diff -p -u -r1.159 htmlengine.h
--- src/htmlengine.h	24 Oct 2002 10:41:08 -0000	1.159
+++ src/htmlengine.h	26 Nov 2002 13:41:05 -0000
@@ -273,6 +273,7 @@ struct _HTMLEngine {
 
 	gboolean save_data;
 	gint saved_step_count;
+	gint autosaved_step_count;
 };
 
 /* must be forward referenced *sigh* */
@@ -473,6 +474,8 @@ void        html_engine_draw_focus_objec
 
 void      html_engine_saved     (HTMLEngine *e);
 gboolean  html_engine_is_saved  (HTMLEngine *e);
+void      html_engine_autosaved (HTMLEngine *e);
+gboolean  html_engine_is_autosaved (HTMLEngine *e);
 
 HTMLMap *html_engine_get_map  (HTMLEngine  *e,
 			       const gchar *name);
