From 5964090053a9b41a0630e998cda166be9cd6aa9a Mon Sep 17 00:00:00 2001 From: Alfons Hoogervorst Date: Sat, 19 Jul 2003 22:24:05 +0000 Subject: [PATCH] * src/mimeview.c o make icon buttons respond on left click o minor cosmetic change --- ChangeLog.claws | 6 ++++++ configure.ac | 2 +- src/mimeview.c | 30 +++++++++++++++++------------- 3 files changed, 24 insertions(+), 14 deletions(-) diff --git a/ChangeLog.claws b/ChangeLog.claws index 9d8964e4f..daa5456dd 100644 --- a/ChangeLog.claws +++ b/ChangeLog.claws @@ -1,3 +1,9 @@ +2003-07-20 [alfons] 0.9.3claws32 + + * src/mimeview.c + o make icon buttons respond on left click + o minor cosmetic change + 2003-07-19 [luke] 0.9.3claws31 * src/mimeview.[ch] diff --git a/configure.ac b/configure.ac index d53d44062..9426177f4 100644 --- a/configure.ac +++ b/configure.ac @@ -11,7 +11,7 @@ MINOR_VERSION=9 MICRO_VERSION=3 INTERFACE_AGE=0 BINARY_AGE=0 -EXTRA_VERSION=31 +EXTRA_VERSION=32 VERSION=${MAJOR_VERSION}.${MINOR_VERSION}.${MICRO_VERSION}claws${EXTRA_VERSION} dnl set $target diff --git a/src/mimeview.c b/src/mimeview.c index 71e9353ce..3e3888ee6 100644 --- a/src/mimeview.c +++ b/src/mimeview.c @@ -1281,18 +1281,20 @@ static gboolean icon_clicked_cb (GtkWidget *button, GdkEventButton *event, MimeV GtkCTreeNode *node; num = GPOINTER_TO_INT(gtk_object_get_data(GTK_OBJECT(button), "icon_number")); partinfo = gtk_object_get_data(GTK_OBJECT(button), "partinfo"); - if (num == 1 && (partinfo->mime_type == MIME_TEXT || - partinfo->mime_type == MIME_TEXT_HTML)) { - gtk_notebook_set_page(GTK_NOTEBOOK(mimeview->notebook), 0); - /* don't set the ctree, as it will unload the plugin, and - * we want to be able to switch quickly between the text - * part and the attachment */ - } else { - gtk_notebook_set_page(GTK_NOTEBOOK(mimeview->notebook), 1); - node = gtk_ctree_find_by_row_data(GTK_CTREE(mimeview->ctree), NULL, partinfo); - if (node) - gtk_ctree_select(GTK_CTREE(mimeview->ctree), node); - } + if (event->button == 1) { + if (num == 1 && (partinfo->mime_type == MIME_TEXT || + partinfo->mime_type == MIME_TEXT_HTML)) { + gtk_notebook_set_page(GTK_NOTEBOOK(mimeview->notebook), 0); + /* don't set the ctree, as it will unload the plugin, and + * we want to be able to switch quickly between the text + * part and the attachment */ + } else { + gtk_notebook_set_page(GTK_NOTEBOOK(mimeview->notebook), 1); + node = gtk_ctree_find_by_row_data(GTK_CTREE(mimeview->ctree), NULL, partinfo); + if (node) + gtk_ctree_select(GTK_CTREE(mimeview->ctree), node); + } + } part_button_pressed(mimeview, event, partinfo); return TRUE; } @@ -1435,7 +1437,9 @@ static void icon_scroll_size_allocate_cb(GtkWidget *widget, gtk_layout_move(GTK_LAYOUT(mimeview->icon_scroll), mimeview->icon_vbox, (mainbox_size->width - vbox_size->width)/2, 0); - gtk_layout_set_size(GTK_LAYOUT(mimeview->icon_scroll), GTK_LAYOUT(mimeview->icon_scroll)->width, MAX(vbox_size->height, layout_size->height)); + gtk_layout_set_size(GTK_LAYOUT(mimeview->icon_scroll), + GTK_LAYOUT(mimeview->icon_scroll)->width, + MAX(vbox_size->height, layout_size->height)); adj->step_increment = 5; } -- 2.25.1