sync with sylpheed 0.5.3cvs5
authorPaul Mangan <paul@claws-mail.org>
Thu, 23 Aug 2001 05:54:21 +0000 (05:54 +0000)
committerPaul Mangan <paul@claws-mail.org>
Thu, 23 Aug 2001 05:54:21 +0000 (05:54 +0000)
ChangeLog
ChangeLog.claws
ChangeLog.jp
configure.in
src/inc.c
src/mainwindow.c
src/mainwindow.h
src/summaryview.c

index 732ae77..4668c6b 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,15 @@
+2001-08-22
+
+       * src/mainwindow.[ch]: added progressbar and status label to the
+         statusbar.
+       * src/inc.c: update the progressbar of main window, too.
+
+2001-08-22
+
+       * src/mainwindow.[ch]: main_window_set_toolbar_sensitive(): removed
+         the second argument, and determine the sensitivity with the
+         state of summary view.
+
 2001-08-21
 
        * src/pop.c: pop3_getsize_list_recv(), pop3_retr_recv(),
index 99dc071..cc5eabc 100644 (file)
@@ -1,3 +1,10 @@
+2001-08-23 [paul]
+
+       * configure.in
+               Change version number to 0.5.3claws3
+
+       * sync with sylpheed 0.5.3cvs5
+
 2001-08-22 [alte]
        * src/Makefile.am, src/compose.[ch], src/defs.h, src/mainwindow.c,
          src/prefs_templates.[ch], src/template.[ch], src/template_select.[ch]
index 991bd2f..ad508fd 100644 (file)
@@ -1,3 +1,15 @@
+2001-08-22
+
+       * src/mainwindow.[ch]: ¥¹¥Æ¡¼¥¿¥¹¥Ð¡¼¤Ë¥×¥í¥°¥ì¥¹¥Ð¡¼¤È¥¹¥Æ¡¼¥¿¥¹
+         ¥é¥Ù¥ë¤òÄɲá£
+       * src/inc.c: ¥á¥¤¥ó¥¦¥£¥ó¥É¥¦¤Î¥×¥í¥°¥ì¥¹¥Ð¡¼¤â¹¹¿·¤¹¤ë¤è¤¦¤Ë¤·¤¿¡£
+
+2001-08-22
+
+       * src/mainwindow.[ch]: main_window_set_toolbar_sensitive(): 2ÈÖÌܤÎ
+         °ú¿ô¤òºï½ü¤·¡¢¥µ¥Þ¥ê¥Ó¥å¡¼¤Î¾õÂ֤Ǡsensitivity ¤ò·èÄꤹ¤ë¤è¤¦¤Ë
+         ¤·¤¿¡£
+
 2001-08-21
 
        * src/pop.c: pop3_getsize_list_recv(), pop3_retr_recv(),
index 362971e..b691f0d 100644 (file)
@@ -11,7 +11,7 @@ MINOR_VERSION=5
 MICRO_VERSION=3
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=claws2
+EXTRA_VERSION=claws3
 VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION
 
 dnl
index 35d1bc6..c43fa79 100644 (file)
--- a/src/inc.c
+++ b/src/inc.c
@@ -27,6 +27,7 @@
 #include <gtk/gtkmain.h>
 #include <gtk/gtkwindow.h>
 #include <gtk/gtksignal.h>
+#include <gtk/gtkprogressbar.h>
 #include <stdio.h>
 #include <unistd.h>
 #include <string.h>
@@ -332,12 +333,16 @@ static void inc_progress_dialog_clear(IncProgressDialog *inc_dialog)
 {
        progress_dialog_set_value(inc_dialog->dialog, 0.0);
        progress_dialog_set_label(inc_dialog->dialog, "");
+       gtk_progress_bar_update
+               (GTK_PROGRESS_BAR(inc_dialog->mainwin->progressbar), 0.0);
 }
 
 static void inc_progress_dialog_destroy(IncProgressDialog *inc_dialog)
 {
        g_return_if_fail(inc_dialog != NULL);
 
+       gtk_progress_bar_update
+               (GTK_PROGRESS_BAR(inc_dialog->mainwin->progressbar), 0.0);
        progress_dialog_destroy(inc_dialog->dialog);
 
        g_free(inc_dialog);
@@ -417,6 +422,9 @@ static gint inc_start(IncProgressDialog *inc_dialog)
        gint error_num = 0;
        gint new_msgs = 0;
 
+       /* gtk_label_set_text(GTK_LABEL(inc_dialog->mainwin->statuslabel),
+                          _("Receiving"));  */
+
        while (inc_dialog->queue_list != NULL) {
                session = inc_dialog->queue_list->data;
                pop3_state = session->pop3_state;
@@ -527,6 +535,8 @@ static gint inc_start(IncProgressDialog *inc_dialog)
                num++;
        }
 
+       /* gtk_label_set_text(GTK_LABEL(inc_dialog->mainwin->statuslabel), "");  */
+
        if (error_num) {
                if (inc_dialog->show_dialog)
                        manage_window_focus_in(inc_dialog->dialog->window,
@@ -826,6 +836,9 @@ static void inc_pop3_recv_func(SockInfo *sock, gint count, gint read_bytes,
 
        progress_dialog_set_percentage
                (dialog, (gfloat)cur_total / (gfloat)state->total_bytes);
+       gtk_progress_bar_update
+               (GTK_PROGRESS_BAR(inc_dialog->mainwin->progressbar),
+                (gfloat)cur_total / (gfloat)state->total_bytes);
        GTK_EVENTS_FLUSH();
 }
 
@@ -880,6 +893,10 @@ void inc_progress_update(Pop3State *state, Pop3Phase phase)
                        (dialog,
                         (gfloat)(state->cur_total_bytes) /
                         (gfloat)(state->total_bytes));
+               gtk_progress_bar_update
+                       (GTK_PROGRESS_BAR(inc_dialog->mainwin->progressbar),
+                        (gfloat)(state->cur_total_bytes) /
+                        (gfloat)(state->total_bytes));
                break;
        case POP3_DELETE_SEND:
        case POP3_DELETE_RECV:
index 4891cce..1e9a39f 100644 (file)
@@ -27,6 +27,7 @@
 #include <gtk/gtkvbox.h>
 #include <gtk/gtkcontainer.h>
 #include <gtk/gtkstatusbar.h>
+#include <gtk/gtkprogressbar.h>
 #include <gtk/gtkhpaned.h>
 #include <gtk/gtkvpaned.h>
 #include <gtk/gtkcheckmenuitem.h>
@@ -596,6 +597,8 @@ MainWindow *main_window_create(SeparateType type)
        GtkWidget *vbox_body;
        GtkWidget *hbox_stat;
        GtkWidget *statusbar;
+       GtkWidget *progressbar;
+       GtkWidget *statuslabel;
        GtkWidget *ac_button;
        GtkWidget *ac_label;
 
@@ -655,6 +658,13 @@ MainWindow *main_window_create(SeparateType type)
        statusbar = statusbar_create();
        gtk_box_pack_start(GTK_BOX(hbox_stat), statusbar, TRUE, TRUE, 0);
 
+       progressbar = gtk_progress_bar_new();
+       gtk_widget_set_usize(progressbar, 120, -1);
+       gtk_box_pack_start(GTK_BOX(hbox_stat), progressbar, FALSE, FALSE, 0);
+
+       statuslabel = gtk_label_new("");
+       gtk_box_pack_start(GTK_BOX(hbox_stat), statuslabel, FALSE, FALSE, 0);
+
        ac_button = gtk_button_new();
        gtk_button_set_relief(GTK_BUTTON(ac_button), GTK_RELIEF_NONE);
        GTK_WIDGET_UNSET_FLAGS(ac_button, GTK_CAN_FOCUS);
@@ -686,15 +696,17 @@ MainWindow *main_window_create(SeparateType type)
 
        messageview->mainwin     = mainwin;
 
-       mainwin->window    = window;
-       mainwin->vbox      = vbox;
-       mainwin->menubar   = menubar;
-       mainwin->handlebox = handlebox;
-       mainwin->vbox_body = vbox_body;
-       mainwin->hbox_stat = hbox_stat;
-       mainwin->statusbar = statusbar;
-       mainwin->ac_button = ac_button;
-       mainwin->ac_label  = ac_label;
+       mainwin->window      = window;
+       mainwin->vbox        = vbox;
+       mainwin->menubar     = menubar;
+       mainwin->handlebox   = handlebox;
+       mainwin->vbox_body   = vbox_body;
+       mainwin->hbox_stat   = hbox_stat;
+       mainwin->statusbar   = statusbar;
+       mainwin->progressbar = progressbar;
+       mainwin->statuslabel = statuslabel;
+       mainwin->ac_button   = ac_button;
+       mainwin->ac_label    = ac_label;
 
        /* set context IDs for status bar */
        mainwin->mainwin_cid = gtk_statusbar_get_context_id
@@ -799,7 +811,7 @@ MainWindow *main_window_create(SeparateType type)
                           GTK_SIGNAL_FUNC(ac_menu_popup_closed), mainwin);
        mainwin->ac_menu = ac_menu;
 
-       main_window_set_toolbar_sensitive(mainwin, FALSE);
+       main_window_set_toolbar_sensitive(mainwin);
 
        /* show main window */
        gtk_widget_set_uposition(mainwin->window,
@@ -1163,8 +1175,15 @@ void main_window_add_mbox(MainWindow *mainwin)
        folderview_set(mainwin->folderview);
 }
 
-void main_window_set_toolbar_sensitive(MainWindow *mainwin, gboolean sensitive)
+void main_window_set_toolbar_sensitive(MainWindow *mainwin)
 {
+       gboolean sensitive;
+
+       if (GTK_CLIST(mainwin->summaryview->ctree)->row_list)
+               sensitive = TRUE;
+       else
+               sensitive = FALSE;
+
        gtk_widget_set_sensitive(mainwin->reply_btn,       sensitive);
        gtk_widget_set_sensitive(mainwin->replyall_btn,    sensitive);
        gtk_widget_set_sensitive(mainwin->replysender_btn, sensitive);
index e8cb412..5315d10 100644 (file)
@@ -111,6 +111,8 @@ struct _MainWindow
        GtkWidget *vbox_body;
        GtkWidget *hbox_stat;
        GtkWidget *statusbar;
+       GtkWidget *progressbar;
+       GtkWidget *statuslabel;
        GtkWidget *ac_button;
        GtkWidget *ac_label;
        GtkWidget *ac_menu;
@@ -152,8 +154,7 @@ void main_window_empty_trash                (MainWindow     *mainwin,
                                         gboolean        confirm);
 void main_window_add_mailbox           (MainWindow     *mainwin);
 
-void main_window_set_toolbar_sensitive (MainWindow     *mainwin,
-                                        gboolean        sensitive);
+void main_window_set_toolbar_sensitive (MainWindow     *mainwin);
 void main_window_set_menu_sensitive    (MainWindow     *mainwin);
 
 void main_window_popup                 (MainWindow     *mainwin);
index ff946d1..5e85875 100644 (file)
@@ -917,13 +917,8 @@ gboolean summary_show(SummaryView *summaryview, FolderItem *item,
        gint sort_type;
         static gboolean locked = FALSE;
 
-       if (locked) {
-               g_print("Summary view is locked, waiting...\n");
+       if (locked)
                return FALSE;
-               /* while (locked)
-                       gtk_main_iteration();
-               g_print("unlocked.\n"); */
-       }
        locked = TRUE;
 
        STATUSBAR_POP(summaryview->mainwin);
@@ -1096,8 +1091,7 @@ gboolean summary_show(SummaryView *summaryview, FolderItem *item,
 
        summary_set_menu_sensitive(summaryview);
 
-       main_window_set_toolbar_sensitive
-               (summaryview->mainwin, summaryview->selected ? TRUE : FALSE);
+       main_window_set_toolbar_sensitive(summaryview->mainwin);
 
        debug_print("\n");
        STATUSBAR_PUSH(summaryview->mainwin, _("Done."));
@@ -1165,7 +1159,7 @@ void summary_clear_all(SummaryView *summaryview)
 {
        summary_clear_list(summaryview);
        summary_set_menu_sensitive(summaryview);
-       main_window_set_toolbar_sensitive(summaryview->mainwin, FALSE);
+       main_window_set_toolbar_sensitive(summaryview->mainwin);
        summary_status_show(summaryview);
 }