2005-10-26 [colin] 1.9.15cvs111
authorColin Leroy <colin@colino.net>
Wed, 26 Oct 2005 16:15:21 +0000 (16:15 +0000)
committerColin Leroy <colin@colino.net>
Wed, 26 Oct 2005 16:15:21 +0000 (16:15 +0000)
* src/gedit-print.c
Fix date format
* src/imap_gtk.c
* src/news_gtk.c
Remove context menu items that should not be there
* src/jpilot.c
Fix encoding
* src/main.c
* src/mainwindow.c
Don't show the mainwindow too soon

ChangeLog-gtk2.claws
PATCHSETS
configure.ac
src/gedit-print.c
src/imap_gtk.c
src/jpilot.c
src/main.c
src/mainwindow.c
src/news_gtk.c

index 5134607..f02efbc 100644 (file)
@@ -1,3 +1,16 @@
+2005-10-26 [colin]     1.9.15cvs111
+
+       * src/gedit-print.c
+               Fix date format
+       * src/imap_gtk.c
+       * src/news_gtk.c
+               Remove context menu items that should not be there
+       * src/jpilot.c
+               Fix encoding
+       * src/main.c
+       * src/mainwindow.c
+               Don't show the mainwindow too soon
+
 2005-10-26 [wwp]       1.9.15cvs110
 
        * src/folder.c
index e8bc178..aa99b35 100644 (file)
--- a/PATCHSETS
+++ b/PATCHSETS
 ( cvs diff -u -r 1.382.2.189 -r 1.382.2.190 src/compose.c;  ) > 1.9.15cvs108.patchset
 ( cvs diff -u -r 1.1.2.1 -r 1.1.2.2 manual/Makefile;  cvs diff -u -r 1.1.2.1 -r 1.1.2.2 manual/faq.xml;  diff -u /dev/null manual/dtd/manual.dsl;  ) > 1.9.15cvs109.patchset
 ( cvs diff -u -r 1.213.2.66 -r 1.213.2.67 src/folder.c;  cvs diff -u -r 1.11.2.2 -r 1.11.2.3 src/manual.c;  cvs diff -u -r 1.395.2.141 -r 1.395.2.142 src/summaryview.c;  ) > 1.9.15cvs110.patchset
+( cvs diff -u -r 1.1.2.3 -r 1.1.2.4 src/gedit-print.c;  cvs diff -u -r 1.1.2.24 -r 1.1.2.25 src/imap_gtk.c;  cvs diff -u -r 1.18.2.13 -r 1.18.2.14 src/jpilot.c;  cvs diff -u -r 1.115.2.62 -r 1.115.2.63 src/main.c;  cvs diff -u -r 1.274.2.76 -r 1.274.2.77 src/mainwindow.c;  cvs diff -u -r 1.2.2.11 -r 1.2.2.12 src/news_gtk.c;  ) > 1.9.15cvs111.patchset
index 35371a5..a210cc9 100644 (file)
@@ -11,7 +11,7 @@ MINOR_VERSION=9
 MICRO_VERSION=15
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=110
+EXTRA_VERSION=111
 EXTRA_RELEASE=
 EXTRA_GTK2_VERSION=
 
index 312116f..9598b6b 100644 (file)
@@ -55,6 +55,7 @@
 #include "gedit-print.h"
 #include "gtk/gtksourceprintjob.h"
 #include "mainwindow.h"
+#include "prefs_common.h"
 
 #ifdef DEBUG
 #  define DEBUG_PRINT "DEBUG_PRINT: %s"
@@ -449,7 +450,7 @@ gedit_print_job_info_new (GtkTextView* view)
        gtk_source_print_job_set_footer_format (pjob,
                                                _("Page %N of %Q"), 
                                                NULL, 
-                                               _("%A %D, %I:%M %p")
+                                               prefs_common.date_format
                                                TRUE);
 
        gtk_source_print_job_set_print_header (pjob, FALSE);
index 6361832..636da9c 100644 (file)
@@ -45,8 +45,6 @@
 static void new_folder_cb(FolderView *folderview, guint action, GtkWidget *widget);
 static void rename_folder_cb(FolderView *folderview, guint action, GtkWidget *widget);
 static void move_folder_cb(FolderView *folderview, guint action, GtkWidget *widget);
-static void imap_settings_cb(FolderView *folderview, guint action, GtkWidget *widget);
-static void remove_server_cb(FolderView *folderview, guint action, GtkWidget *widget);
 static void delete_folder_cb(FolderView *folderview, guint action, GtkWidget *widget);
 static void update_tree_cb(FolderView *folderview, guint action, GtkWidget *widget);
 static void download_cb(FolderView *folderview, guint action, GtkWidget *widget);
@@ -66,9 +64,6 @@ static GtkItemFactoryEntry imap_popup_entries[] =
        {N_("/C_heck for new folders"),  NULL, update_tree_cb,   1, NULL},
        {N_("/R_ebuild folder tree"),    NULL, update_tree_cb,   2, NULL},
        {N_("/---"),                     NULL, NULL,             0, "<Separator>"},
-       {N_("/IMAP4 _account settings"), NULL, imap_settings_cb, 0, NULL},
-       {N_("/Remove _IMAP4 account"),   NULL, remove_server_cb, 0, NULL},
-       {N_("/---"),                     NULL, NULL,             0, "<Separator>"},
 };
 
 static void set_sensitivity(GtkItemFactory *factory, FolderItem *item);
@@ -114,8 +109,6 @@ static void set_sensitivity(GtkItemFactory *factory, FolderItem *item)
        SET_SENS("/Check for new folders",  folder_item_parent(item) == NULL);
        SET_SENS("/Rebuild folder tree",    folder_item_parent(item) == NULL);
 
-       SET_SENS("/Remove IMAP4 account",   folder_item_parent(item) == NULL);
-
 #undef SET_SENS
 }
 
@@ -249,61 +242,6 @@ static void move_folder_cb(FolderView *folderview, guint action, GtkWidget *widg
        folderview_move_folder(folderview, from_folder, to_folder);
 }
 
-static void imap_settings_cb(FolderView *folderview, guint action, GtkWidget *widget)
-{
-       FolderItem *item;
-
-       item = folderview_get_selected_item(folderview);
-       if (item == NULL)
-               return;
-
-       account_open(item->folder->account);
-}
-
-static void remove_server_cb(FolderView *folderview, guint action, GtkWidget *widget)
-{
-       GtkCTree *ctree = GTK_CTREE(folderview->ctree);
-       FolderItem *item;
-       PrefsAccount *account;
-       gchar *name;
-       gchar *message;
-       AlertValue avalue;
-
-       if (!folderview->selected) return;
-
-       item = gtk_ctree_node_get_row_data(ctree, folderview->selected);
-       g_return_if_fail(item != NULL);
-       g_return_if_fail(item->folder != NULL);
-       g_return_if_fail(item->folder->account != NULL);
-
-       name = trim_string(item->folder->name, 32);
-       message = g_strdup_printf(_("Really delete IMAP4 account '%s'?"), name);
-       avalue = alertpanel_full(_("Delete IMAP4 account"), message,
-                                GTK_STOCK_YES, GTK_STOCK_NO, NULL, FALSE,
-                                NULL, ALERT_WARNING, G_ALERTALTERNATE);
-       g_free(message);
-       g_free(name);
-
-       if (avalue != G_ALERTDEFAULT) return;
-
-       if (folderview->opened == folderview->selected ||
-           gtk_ctree_is_ancestor(ctree,
-                                 folderview->selected,
-                                 folderview->opened)) {
-               summary_clear_all(folderview->summaryview);
-               folderview->opened = NULL;
-       }
-
-       account = item->folder->account;
-       folderview_unselect(folderview);
-       summary_clear_all(folderview->summaryview);
-       folder_destroy(item->folder);
-       account_destroy(account);
-       account_set_menu();
-       main_window_reflect_prefs_all();
-       folder_write_list();
-}
-
 static void delete_folder_cb(FolderView *folderview, guint action,
                             GtkWidget *widget)
 {
index a397af1..5e67c96 100644 (file)
@@ -1101,7 +1101,9 @@ static void jpilot_parse_label( JPilotFile *pilotFile, gchar *labelEntry, ItemPe
                        addritem_email_set_address( email, node->data );
                        if (convert_charcode) {
                                gchar *convertBuff;
-                               convertBuff = conv_codeset_strdup( labelEntry, conv_get_locale_charset_str(), CS_INTERNAL );
+                               convertBuff = conv_codeset_strdup( labelEntry, 
+                                               conv_get_locale_charset_str_no_utf8(), 
+                                               CS_INTERNAL );
                                addritem_email_set_remarks( email, convertBuff );
                                g_free( convertBuff );
                        }
@@ -1183,7 +1185,9 @@ static void jpilot_load_address(
 
                if( convert_charcode ) {
                        gchar *nameConv;
-                       nameConv = conv_codeset_strdup( fullName, conv_get_locale_charset_str(), CS_INTERNAL );
+                       nameConv = conv_codeset_strdup( fullName, 
+                                       conv_get_locale_charset_str_no_utf8(), 
+                                       CS_INTERNAL );
                        strncpy2( fullName, nameConv, FULLNAME_BUFSIZE );
                        g_free( nameConv );
                }
@@ -1350,7 +1354,9 @@ static gboolean jpilot_setup_labels( JPilotFile *pilotFile ) {
                                gchar convertBuff[ JPILOT_LEN_LABEL ];
 
                                if( convert_charcode ) {
-                                       labelName = conv_codeset_strdup( labelName, conv_get_locale_charset_str(), CS_INTERNAL );
+                                       labelName = conv_codeset_strdup( labelName, 
+                                                       conv_get_locale_charset_str_no_utf8(), 
+                                                       CS_INTERNAL );
                                        strncpy2( convertBuff, labelName, JPILOT_LEN_LABEL );
                                        g_free( labelName );
                                        labelName = convertBuff;
@@ -1388,7 +1394,9 @@ GList *jpilot_load_label( JPilotFile *pilotFile, GList *labelList ) {
 
                        if( labelName ) {
                                if( convert_charcode ) {
-                                       labelName = conv_codeset_strdup( labelName, conv_get_locale_charset_str(), CS_INTERNAL );
+                                       labelName = conv_codeset_strdup( labelName, 
+                                                       conv_get_locale_charset_str_no_utf8(), 
+                                                       CS_INTERNAL );
                                }
                                else {
                                        labelName = g_strdup( labelName );
@@ -1478,7 +1486,9 @@ GList *jpilot_load_custom_label( JPilotFile *pilotFile, GList *labelList ) {
                                g_strchug( labelName );
                                if( *labelName != '\0' ) {
                                        if( convert_charcode ) {
-                                               labelName = conv_codeset_strdup( labelName, conv_get_locale_charset_str(), CS_INTERNAL );
+                                               labelName = conv_codeset_strdup( labelName, 
+                                                               conv_get_locale_charset_str_no_utf8(), 
+                                                               CS_INTERNAL );
                                        }
                                        else {
                                                labelName = g_strdup( labelName );
@@ -1534,7 +1544,9 @@ static void jpilot_build_category_list( JPilotFile *pilotFile ) {
 
                if( convert_charcode ) {
                        gchar *catName;
-                       catName = conv_codeset_strdup( cat->name[i], conv_get_locale_charset_str(), CS_INTERNAL );
+                       catName = conv_codeset_strdup( cat->name[i], 
+                                       conv_get_locale_charset_str_no_utf8(), 
+                                       CS_INTERNAL );
                        addritem_folder_set_name( folder, catName );
                        g_free( catName );
                }
index 2584f3a..bae9fdb 100644 (file)
@@ -219,6 +219,8 @@ static void startup_notification_complete(gboolean with_window)
                sn_launchee_context_unref(sn_context);
                sn_display_unref(sn_display);
        }
+       if (with_window)
+               gtk_widget_destroy(hack);
 }
 #endif /* HAVE_STARTUP_NOTIFICATION */
 
@@ -458,6 +460,8 @@ int main(int argc, char *argv[])
                        exit_sylpheed(mainwin);
        }
 
+       gtk_window_deiconify(mainwin->window);
+
 #ifdef HAVE_LIBETPAN
        imap_main_init();
 #endif 
index 0c14431..2901cf1 100644 (file)
@@ -1114,8 +1114,8 @@ MainWindow *main_window_create(SeparateType type)
        menu_connect_identical_items();
 
 
-       
-       /* show main window */
+       gtk_window_iconify(mainwin->window);
+
        gtk_widget_show(mainwin->window);
 
        /* initialize views */
index 52108e4..eb67a4c 100644 (file)
@@ -42,8 +42,6 @@
 
 static void subscribe_newsgroup_cb(FolderView *folderview, guint action, GtkWidget *widget);
 static void unsubscribe_newsgroup_cb(FolderView *folderview, guint action, GtkWidget *widget);
-static void news_settings_cb(FolderView *folderview, guint action, GtkWidget *widget);
-static void remove_news_server_cb(FolderView *folderview, guint action, GtkWidget *widget);
 static void update_tree_cb(FolderView *folderview, guint action, GtkWidget *widget);
 static void download_cb(FolderView *folderview, guint action, GtkWidget *widget);
 static void sync_cb(FolderView *folderview, guint action, GtkWidget *widget);
@@ -58,9 +56,6 @@ static GtkItemFactoryEntry news_popup_entries[] =
        {N_("/---"),                            NULL, NULL,                      0, "<Separator>"},
        {N_("/_Check for new messages"),        NULL, update_tree_cb,            0, NULL},
        {N_("/---"),                            NULL, NULL,                      0, "<Separator>"},
-       {N_("/News _account settings"),         NULL, news_settings_cb,          0, NULL},
-       {N_("/Remove _news account"),           NULL, remove_news_server_cb,     0, NULL},
-       {N_("/---"),                            NULL, NULL,                      0, "<Separator>"},
 };
 
 static void set_sensitivity(GtkItemFactory *factory, FolderItem *item);
@@ -92,8 +87,6 @@ static void set_sensitivity(GtkItemFactory *factory, FolderItem *item)
 
        SET_SENS("/Subscribe to newsgroup...", folder_item_parent(item) == NULL);
        SET_SENS("/Unsubscribe newsgroup",     folder_item_parent(item) != NULL);
-       SET_SENS("/Remove news account",       folder_item_parent(item) == NULL);
-
        SET_SENS("/Check for new messages",    folder_item_parent(item) == NULL);
 
 #undef SET_SENS
@@ -225,63 +218,6 @@ static void unsubscribe_newsgroup_cb(FolderView *folderview, guint action,
        g_free(old_id);
 }
 
-static void news_settings_cb(FolderView *folderview, guint action, GtkWidget *widget)
-{
-       FolderItem *item;
-
-       item = folderview_get_selected_item(folderview);
-       if (item == NULL)
-               return;
-
-       account_open(item->folder->account);
-}
-
-static void remove_news_server_cb(FolderView *folderview, guint action,
-                                 GtkWidget *widget)
-{
-       GtkCTree *ctree = GTK_CTREE(folderview->ctree);
-       FolderItem *item;
-       PrefsAccount *account;
-       gchar *name;
-       gchar *message;
-       AlertValue avalue;
-
-       if (!folderview->selected) return;
-
-       item = gtk_ctree_node_get_row_data(ctree, folderview->selected);
-       g_return_if_fail(item != NULL);
-       g_return_if_fail(item->folder != NULL);
-       g_return_if_fail(FOLDER_TYPE(item->folder) == F_NEWS);
-       g_return_if_fail(item->folder->account != NULL);
-
-       name = trim_string(item->folder->name, 32);
-       message = g_strdup_printf(_("Really delete news account '%s'?"), name);
-       avalue = alertpanel_full(_("Delete news account"), message,
-                                GTK_STOCK_YES, GTK_STOCK_NO, NULL, FALSE,
-                                NULL, ALERT_WARNING, G_ALERTALTERNATE);
-       g_free(message);
-       g_free(name);
-
-       if (avalue != G_ALERTDEFAULT) return;
-
-       if (folderview->opened == folderview->selected ||
-           gtk_ctree_is_ancestor(ctree,
-                                 folderview->selected,
-                                 folderview->opened)) {
-               summary_clear_all(folderview->summaryview);
-               folderview->opened = NULL;
-       }
-
-       account = item->folder->account;
-       folderview_unselect(folderview);
-       summary_clear_all(folderview->summaryview);
-       folder_destroy(item->folder);
-       account_destroy(account);
-       account_set_menu();
-       main_window_reflect_prefs_all();
-       folder_write_list();
-}
-
 static void update_tree_cb(FolderView *folderview, guint action,
                           GtkWidget *widget)
 {