2008-06-12 [colin] 3.4.0cvs91
authorColin Leroy <colin@colino.net>
Thu, 12 Jun 2008 16:45:25 +0000 (16:45 +0000)
committerColin Leroy <colin@colino.net>
Thu, 12 Jun 2008 16:45:25 +0000 (16:45 +0000)
* src/compose.c
* src/compose.h
Fix bug 1635, 'Last character of message is truncated
when changing accounts w/ sigs'
* src/folderview.c
Fix bug 1636, 'Can't select "properties" on "folders
only" folders'

ChangeLog
PATCHSETS
configure.ac
src/compose.c
src/compose.h
src/folderview.c

index ce67b79..5d1566a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2008-06-12 [colin]     3.4.0cvs91
+
+       * src/compose.c
+       * src/compose.h
+               Fix bug 1635, 'Last character of message is truncated 
+               when changing accounts w/ sigs'
+       * src/folderview.c
+               Fix bug 1636, 'Can't select "properties" on "folders 
+               only" folders'
+
 2008-06-11 [colin]     3.4.0cvs90
 
        * src/folder.c
index 009a0d7..8b68d20 100644 (file)
--- a/PATCHSETS
+++ b/PATCHSETS
 ( cvs diff -u -r 1.42.2.38 -r 1.42.2.39 po/fr.po;  ) > 3.4.0cvs88.patchset
 ( cvs diff -u -r 1.100.2.61 -r 1.100.2.62 AUTHORS;  cvs diff -u -r 1.25.2.26 -r 1.25.2.27 tools/Makefile.am;  cvs diff -u -r 1.30.2.30 -r 1.30.2.31 tools/README;  cvs diff -u -r -1.1.2.1 -r -1.1.2.2 tools/convert_mbox.sh;  ) > 3.4.0cvs89.patchset
 ( cvs diff -u -r 1.213.2.183 -r 1.213.2.184 src/folder.c;  ) > 3.4.0cvs90.patchset
+( cvs diff -u -r 1.382.2.451 -r 1.382.2.452 src/compose.c;  cvs diff -u -r 1.50.2.46 -r 1.50.2.47 src/compose.h;  cvs diff -u -r 1.207.2.200 -r 1.207.2.201 src/folderview.c;  ) > 3.4.0cvs91.patchset
index 00b01b3..d16fd3c 100644 (file)
@@ -11,7 +11,7 @@ MINOR_VERSION=4
 MICRO_VERSION=0
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=90
+EXTRA_VERSION=91
 EXTRA_RELEASE=
 EXTRA_GTK2_VERSION=
 
index 9db7fa5..97ce9ed 100644 (file)
@@ -3266,7 +3266,7 @@ static void compose_insert_sig(Compose *compose, gboolean replace)
 
                if (found) {
                        /* include previous \n\n */
-                       gtk_text_iter_backward_chars(&first_iter, 2);
+                       gtk_text_iter_backward_chars(&first_iter, 1);
                        start_iter = first_iter;
                        end_iter = first_iter;
                        /* skip re-start */
@@ -3290,10 +3290,15 @@ static void compose_insert_sig(Compose *compose, gboolean replace)
                g_free(compose->sig_str);
                compose->sig_str = NULL;
        } else {
+               if (compose->sig_inserted == FALSE)
+                       gtk_text_buffer_insert(buffer, &iter, "\n", -1);
+               compose->sig_inserted = TRUE;
+
+               cur_pos = gtk_text_iter_get_offset(&iter);
                gtk_text_buffer_insert(buffer, &iter, compose->sig_str, -1);
                /* remove \n\n */
                gtk_text_buffer_get_iter_at_offset(buffer, &iter, cur_pos);
-               gtk_text_iter_forward_chars(&iter, 2);
+               gtk_text_iter_forward_chars(&iter, 1);
                gtk_text_buffer_get_end_iter(buffer, &iter_end);
                gtk_text_buffer_apply_tag_by_name(buffer,"signature",&iter, &iter_end);
 
@@ -3348,11 +3353,11 @@ static gchar *compose_get_signature_str(Compose *compose)
        }
 
        if (compose->account->sig_sep) {
-               sig_str = g_strconcat("\n\n", compose->account->sig_sep, "\n", sig_body,
+               sig_str = g_strconcat("\n", compose->account->sig_sep, "\n", sig_body,
                                      NULL);
                g_free(sig_body);
        } else
-               sig_str = g_strconcat("\n\n", sig_body, NULL);
+               sig_str = g_strconcat("\n", sig_body, NULL);
 
        if (sig_str) {
                if (g_utf8_validate(sig_str, -1, NULL) == TRUE)
index acaeff9..94ef6ab 100644 (file)
@@ -192,6 +192,7 @@ struct _Compose
        UndoMain *undostruct;
 
        gchar *sig_str;
+       gboolean sig_inserted;
 
        /* external editor */
        gchar      *exteditor_file;
index 70e1bf7..4e03dc2 100644 (file)
@@ -1964,7 +1964,7 @@ static void folderview_set_sens_and_popup_menu(FolderView *folderview, gint row,
        SET_SENS("/Mark all read", item->unread_msgs >= 1);
        SET_SENS("/Search folder...", item->total_msgs >= 1 && 
                 folderview->selected == folderview->opened);
-       SET_SENS("/Properties...", !item->no_select);
+       SET_SENS("/Properties...", TRUE);
 
        SET_SENS("/Run processing rules", item->prefs->processing &&
                 item->total_msgs >= 1 && !item->processing_pending);