aboutsummaryrefslogtreecommitdiff
path: root/src/compose.c
diff options
context:
space:
mode:
authorhiro <hiro@ee746299-78ed-0310-b773-934348b2243d>2005-02-25 08:08:49 +0000
committerhiro <hiro@ee746299-78ed-0310-b773-934348b2243d>2005-02-25 08:08:49 +0000
commit19a51bbe411d98970bcebcec1e559d60b02899b0 (patch)
treeb5bf6838fa018a4bf6029c9bc0816769fc765f0e /src/compose.c
parent3bc07b606590d43c4e84cc0182941d30f8c54e67 (diff)
replaced GtkFileSelection with GtkFileChooserDialog.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@128 ee746299-78ed-0310-b773-934348b2243d
Diffstat (limited to 'src/compose.c')
-rw-r--r--src/compose.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/compose.c b/src/compose.c
index 15dca3ad..2e160099 100644
--- a/src/compose.c
+++ b/src/compose.c
@@ -5246,28 +5246,34 @@ static void compose_draft_cb(gpointer data, guint action, GtkWidget *widget)
static void compose_attach_cb(gpointer data, guint action, GtkWidget *widget)
{
Compose *compose = (Compose *)data;
- const gchar *file;
+ gchar *file;
gchar *utf8_filename;
- file = filesel_select_file(_("Select file"), NULL);
+ file = filesel_select_file(_("Select file"), NULL,
+ GTK_FILE_CHOOSER_ACTION_OPEN);
if (file && *file) {
utf8_filename = conv_filename_to_utf8(file);
compose_attach_append(compose, file, utf8_filename, NULL);
g_free(utf8_filename);
}
+
+ g_free(file);
}
static void compose_insert_file_cb(gpointer data, guint action,
GtkWidget *widget)
{
Compose *compose = (Compose *)data;
- const gchar *file;
+ gchar *file;
- file = filesel_select_file(_("Select file"), NULL);
+ file = filesel_select_file(_("Select file"), NULL,
+ GTK_FILE_CHOOSER_ACTION_OPEN);
if (file && *file)
compose_insert_file(compose, file);
+
+ g_free(file);
}
static void compose_insert_sig_cb(gpointer data, guint action,