From: Colin Leroy Date: Wed, 16 Feb 2005 09:28:53 +0000 (+0000) Subject: 2005-02-16 [colin] 1.0.1cvs11.2 X-Git-Tag: rel_1_9_6~36 X-Git-Url: http://git.claws-mail.org/?p=claws.git;a=commitdiff_plain;h=c50a58a1d1376fd6ee7fbdac2f038706ea0b6fa5 2005-02-16 [colin] 1.0.1cvs11.2 * src/messageview.c Fix messageview_select_all --- diff --git a/ChangeLog-gtk2.claws b/ChangeLog-gtk2.claws index 33a74b166..93418ee35 100644 --- a/ChangeLog-gtk2.claws +++ b/ChangeLog-gtk2.claws @@ -1,3 +1,8 @@ +2005-02-16 [colin] 1.0.1cvs11.2 + + * src/messageview.c + Fix messageview_select_all + 2005-02-16 [colin] 1.0.1cvs11.1 * src/mh.c diff --git a/PATCHSETS b/PATCHSETS index c12d47bd6..f4a81ba4e 100644 --- a/PATCHSETS +++ b/PATCHSETS @@ -383,3 +383,4 @@ ( cvs diff -u -r 1.5.2.11 -r 1.5.2.12 src/gtk/pluginwindow.c; ) > 1.0.1cvs7.3.patchset ( cvs diff -u -r 1.83.2.30 -r 1.83.2.31 src/mimeview.c; cvs diff -u -r 1.36.2.23 -r 1.36.2.25 src/common/utils.c; ) > 1.0.1cvs8.1.patchset ( cvs diff -u -r 1.79.2.8 -r 1.79.2.9 src/mh.c; ) > 1.0.1cvs11.1.patchset +( cvs diff -u -r 1.94.2.45 -r 1.94.2.46 src/messageview.c; ) > 1.0.1cvs11.2.patchset diff --git a/configure.ac b/configure.ac index 452374942..fc68c0274 100644 --- a/configure.ac +++ b/configure.ac @@ -13,7 +13,7 @@ INTERFACE_AGE=0 BINARY_AGE=0 EXTRA_VERSION=11 EXTRA_RELEASE= -EXTRA_GTK2_VERSION=.1 +EXTRA_GTK2_VERSION=.2 if test \( $EXTRA_VERSION -eq 0 \) -o \( "x$EXTRA_RELEASE" != "x" \); then VERSION=${MAJOR_VERSION}.${MINOR_VERSION}.${MICRO_VERSION}${EXTRA_RELEASE}${EXTRA_GTK2_VERSION} diff --git a/src/messageview.c b/src/messageview.c index 9e9e1fe66..e67f84b33 100644 --- a/src/messageview.c +++ b/src/messageview.c @@ -914,10 +914,28 @@ void messageview_copy_clipboard(MessageView *messageview) void messageview_select_all(MessageView *messageview) { TextView *text; + GtkTextView *edit = NULL; + GtkTextBuffer *textbuf; + gint body_pos = 0; + GtkTextIter start, end; + + g_return_if_fail(messageview != NULL); text = messageview_get_current_textview(messageview); - if (text) - gtk_editable_select_region(GTK_EDITABLE(text->text), 0, -1); + g_return_if_fail(text != NULL); + + edit = GTK_TEXT_VIEW(text->text); + g_return_if_fail(edit != NULL); + + textbuf = gtk_text_view_get_buffer(edit); + g_return_if_fail(textbuf != NULL); + + gtk_text_buffer_get_bounds(textbuf, &start, &end); + + gtk_text_buffer_move_mark_by_name(textbuf, + "selection_bound", &start); + gtk_text_buffer_move_mark_by_name(textbuf, + "insert", &end); } void messageview_set_position(MessageView *messageview, gint pos)