From 233692e83d0d59372930fe05f03d6d3006524641 Mon Sep 17 00:00:00 2001 From: Oliver Haertel Date: Fri, 29 Nov 2002 15:36:33 +0000 Subject: [PATCH] disable compose button by default, move deleted msgs to trash --- ChangeLog.claws | 6 ++++++ configure.in | 2 +- src/toolbar.c | 30 +++++++++++++++++------------- 3 files changed, 24 insertions(+), 14 deletions(-) diff --git a/ChangeLog.claws b/ChangeLog.claws index b025f8700..a71db9d0b 100644 --- a/ChangeLog.claws +++ b/ChangeLog.claws @@ -1,3 +1,9 @@ +2002-11-29 [oliver] 0.8.6claws37 + + * src/toolbar.c + disable compose button (messageview toolbar) by default + deleted msgs are moved to trash + 2002-11-29 [melvin] 0.8.6claws36 * configure.in diff --git a/configure.in b/configure.in index 5f7fa6585..fc69c00a4 100644 --- a/configure.in +++ b/configure.in @@ -11,7 +11,7 @@ MINOR_VERSION=8 MICRO_VERSION=6 INTERFACE_AGE=0 BINARY_AGE=0 -EXTRA_VERSION=claws36 +EXTRA_VERSION=claws37 VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION dnl set $target diff --git a/src/toolbar.c b/src/toolbar.c index 678c3d5d0..49d06fb85 100644 --- a/src/toolbar.c +++ b/src/toolbar.c @@ -40,6 +40,7 @@ #include "xml.h" #include "mgutils.h" #include "prefs.h" +#include "folder.h" #include "codeconv.h" #include "stock_pixmap.h" #include "mainwindow.h" @@ -49,7 +50,6 @@ #include "prefs_actions.h" #include "manage_window.h" #include "gtkutils.h" - #include "toolbar.h" #include "prefs_toolbar.h" @@ -349,8 +349,8 @@ static void toolbar_set_default_msgview(void) gint icon; gchar *text; } default_toolbar[] = { - { A_COMPOSE_EMAIL, STOCK_PIXMAP_MAIL_COMPOSE, _("Email") }, - { A_SEPARATOR, 0, ("") }, + /*{ A_COMPOSE_EMAIL, STOCK_PIXMAP_MAIL_COMPOSE, _("Email") }, + { A_SEPARATOR, 0, ("") },*/ { A_REPLY_MESSAGE, STOCK_PIXMAP_MAIL_REPLY, _("Reply") }, { A_REPLY_ALL, STOCK_PIXMAP_MAIL_REPLY_TO_ALL, _("All") }, { A_REPLY_SENDER, STOCK_PIXMAP_MAIL_REPLY_TO_AUTHOR, _("Sender") }, @@ -593,13 +593,6 @@ void toolbar_action_execute(GtkWidget *widget, g_warning ("Error: did not find Sylpheed Action to execute"); } -static ToolbarType detect_window(gpointer data) -{ - g_return_val_if_fail(data != NULL, -1); - - return ((ToolbarParent*)data)->type; -} - /* * Change the style of toolbar */ @@ -667,15 +660,26 @@ void common_toolbar_delete_cb(GtkWidget *widget, ToolbarParent *parent = (ToolbarParent*)data; MainWindow *mainwin; MessageView *msgview; + GList *cur; + GtkCTreeNode *sel_last = NULL; + GtkCTreeNode *node; + MsgInfo *msginfo; + SummaryView *summaryview; g_return_if_fail(parent != NULL); switch (parent->type) { case TOOLBAR_MSGVIEW: msgview = (MessageView*)parent->data; - folder_item_remove_msg(msgview->msginfo->folder, - msgview->msginfo->msgnum); -/** TODO: The summaryview must be updated.... **/ + summaryview = msgview->mainwin->summaryview; + summary_delete(summaryview); + /* do we really want to close the widget ? + I`d rather have it staying open and moving to next msg + in summaryview ... - oha + */ + toolbar_clear_list(TOOLBAR_MSGVIEW); + TOOLBAR_DESTROY_ITEMS(msgview->toolbar->item_list); + TOOLBAR_DESTROY_ACTIONS(msgview->toolbar->action_list); gtk_widget_destroy(msgview->window); break; case TOOLBAR_MAIN: -- 2.25.1