aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhiro <hiro@ee746299-78ed-0310-b773-934348b2243d>2005-11-09 08:14:18 +0000
committerhiro <hiro@ee746299-78ed-0310-b773-934348b2243d>2005-11-09 08:14:18 +0000
commit6d37549cb31c4b58481ab4b6385232e21d3f481c (patch)
tree2148fc0fbb000bdd636742f1430a6cb440ef49e9
parent7865aa3f0aaea42214de82b6d3f820fb8f768ad5 (diff)
allow drop of files in the whole compose window. Disabled insertion of text by DnD.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@729 ee746299-78ed-0310-b773-934348b2243d
-rw-r--r--ChangeLog5
-rw-r--r--ChangeLog.ja5
-rw-r--r--configure.in2
-rw-r--r--src/compose.c19
4 files changed, 16 insertions, 15 deletions
diff --git a/ChangeLog b/ChangeLog
index 22ede048..806ee142 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2005-11-09
+
+ * src/compose.c: allow drop of files in the whole window. Disabled
+ insertion of text by DnD.
+
2005-11-08
* version 2.1.6
diff --git a/ChangeLog.ja b/ChangeLog.ja
index 0fb6cae0..b5fbf0d6 100644
--- a/ChangeLog.ja
+++ b/ChangeLog.ja
@@ -1,3 +1,8 @@
+2005-11-09
+
+ * src/compose.c: ウィンドウ全体でファイルのドロップを有効にした。
+ DnD によるテキストの挿入を無効にした。
+
2005-11-08
* version 2.1.6
diff --git a/configure.in b/configure.in
index 2581290a..11f818c0 100644
--- a/configure.in
+++ b/configure.in
@@ -9,7 +9,7 @@ MINOR_VERSION=1
MICRO_VERSION=6
INTERFACE_AGE=0
BINARY_AGE=0
-EXTRA_VERSION=
+EXTRA_VERSION=+svn
VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION
dnl set $target
diff --git a/src/compose.c b/src/compose.c
index 8be5a1ec..0b886964 100644
--- a/src/compose.c
+++ b/src/compose.c
@@ -4150,10 +4150,10 @@ static Compose *compose_create(PrefsAccount *account, ComposeMode mode)
G_CALLBACK(attach_key_pressed), compose);
/* drag and drop */
- gtk_drag_dest_set(attach_treeview,
+ gtk_drag_dest_set(window,
GTK_DEST_DEFAULT_ALL, compose_drag_types,
N_DRAG_TYPES, GDK_ACTION_COPY | GDK_ACTION_MOVE);
- g_signal_connect(G_OBJECT(attach_treeview), "drag-data-received",
+ g_signal_connect(G_OBJECT(window), "drag-data-received",
G_CALLBACK(compose_attach_drag_received_cb),
compose);
@@ -6307,8 +6307,6 @@ static void compose_insert_drag_received_cb (GtkWidget *widget,
guint time,
gpointer user_data)
{
- Compose *compose = (Compose *)user_data;
- GList *list, *cur;
static GdkDragContext *context_ = NULL;
static gint x_ = -1, y_ = -1;
static guint info_ = N_DRAG_TYPES;
@@ -6321,7 +6319,7 @@ static void compose_insert_drag_received_cb (GtkWidget *widget,
* This hack prevents duplicated insertion. */
if (context_ == drag_context && x_ == x && y_ == y && info_ == info &&
time_ == time) {
- debug_print("dup event\n");
+ debug_print("dup drag-data-received event\n");
context_ = NULL;
x_ = y_ = -1;
info_ = N_DRAG_TYPES;
@@ -6334,15 +6332,8 @@ static void compose_insert_drag_received_cb (GtkWidget *widget,
info_ = info;
time_ = time;
- list = uri_list_extract_filenames((const gchar *)data->data);
- for (cur = list; cur != NULL; cur = cur->next)
- compose_insert_file(compose, (const gchar *)cur->data, TRUE);
- list_free_strings(list);
- g_list_free(list);
-
- if ((drag_context->actions & GDK_ACTION_MOVE) != 0)
- drag_context->action = 0;
- gtk_drag_finish(drag_context, TRUE, FALSE, time);
+ compose_attach_drag_received_cb(widget, drag_context, x, y, data,
+ info, time, user_data);
}
static void to_activated(GtkWidget *widget, Compose *compose)