fname = mimeview->file;
if (!fname) return;
- if ((fp = fopen(fname, "rb")) == NULL) {
+ if ((fp = g_fopen(fname, "rb")) == NULL) {
FILE_OP_ERROR(fname, "fopen");
return;
}
startdir = g_strconcat(prefs_common.attach_save_dir,
G_DIR_SEPARATOR_S, NULL);
- dirname = filesel_select_file_open_folder(_("Select destination folder"), startdir);
+ dirname = filesel_select_file_save_folder(_("Select destination folder"), startdir);
if (!dirname) {
if (startdir) g_free(startdir);
return;
}
if (!is_dir_exist (dirname)) {
- alertpanel_error(_("`%s' is not a directory."),
+ alertpanel_error(_("'%s' is not a directory."),
dirname);
if (startdir) g_free(startdir);
return;
cmd = input_dialog_combo
(_("Open with"),
_("Enter the command line to open file:\n"
- "(`%s' will be replaced with file name)"),
+ "('%s' will be replaced with file name)"),
prefs_common.mime_open_cmd,
prefs_common.mime_open_cmd_history,
TRUE);
static void mimeview_view_file(const gchar *filename, MimeInfo *partinfo,
const gchar *cmdline)
{
- static gchar *default_image_cmdline = "display '%s'";
- static gchar *default_audio_cmdline = "play '%s'";
+ static gchar *default_image_cmdline = DEFAULT_IMAGE_VIEWER_CMD;
+ static gchar *default_audio_cmdline = DEFAULT_AUDIO_PLAYER_CMD;
static gchar *default_html_cmdline = DEFAULT_BROWSER_CMD;
- static gchar *mime_cmdline = "metamail -d -b -x -c %s '%s'";
+ static gchar *mime_cmdline = DEFAULT_MIME_CMD;
gchar buf[1024];
gchar m_buf[1024];
const gchar *cmd;
g_snprintf(buf, sizeof(buf), cmd, filename);
else {
if (cmd)
- g_warning("MIME viewer command line is invalid: `%s'", cmd);
+ g_warning("MIME viewer command line is invalid: '%s'", cmd);
if (def_cmd)
g_snprintf(buf, sizeof(buf), def_cmd, filename);
else