aboutsummaryrefslogtreecommitdiffstats
path: root/lib/ephy-file-helpers.h
diff options
context:
space:
mode:
authorChristian Persch <chpe@cvs.gnome.org>2005-01-01 00:09:40 +0800
committerChristian Persch <chpe@src.gnome.org>2005-01-01 00:09:40 +0800
commit9b8959a4de1dc5eacdf807ae6d311defce4fad51 (patch)
tree88ac3f23c1b1024b3b6d7101bbc6712ebd943e74 /lib/ephy-file-helpers.h
parentddf12994065314b103f57969640845d7344974f2 (diff)
downloadgsoc2013-epiphany-9b8959a4de1dc5eacdf807ae6d311defce4fad51.tar
gsoc2013-epiphany-9b8959a4de1dc5eacdf807ae6d311defce4fad51.tar.gz
gsoc2013-epiphany-9b8959a4de1dc5eacdf807ae6d311defce4fad51.tar.bz2
gsoc2013-epiphany-9b8959a4de1dc5eacdf807ae6d311defce4fad51.tar.lz
gsoc2013-epiphany-9b8959a4de1dc5eacdf807ae6d311defce4fad51.tar.xz
gsoc2013-epiphany-9b8959a4de1dc5eacdf807ae6d311defce4fad51.tar.zst
gsoc2013-epiphany-9b8959a4de1dc5eacdf807ae6d311defce4fad51.zip
Move mime permission checks to ephy-file-helpers.
2004-12-31 Christian Persch <chpe@cvs.gnome.org> * embed/ephy-embed-shell.c: (ephy_embed_shell_finalize), (ephy_embed_shell_get_encodings): * embed/ephy-embed-shell.h: * embed/mozilla/ContentHandler.cpp: * embed/mozilla/ContentHandler.h: * lib/ephy-file-helpers.c: (ephy_file_helpers_shutdown), (ephy_file_delete_on_exit), (load_mime_from_xml), (ephy_file_check_mime): * lib/ephy-file-helpers.h: Move mime permission checks to ephy-file-helpers. * src/popup-commands.c: (image_open_uri), (save_source_completed_cb), (popup_cmd_open_image): Only open the image if its mime type is 'safe'.
Diffstat (limited to 'lib/ephy-file-helpers.h')
-rw-r--r--lib/ephy-file-helpers.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/ephy-file-helpers.h b/lib/ephy-file-helpers.h
index 6beb2951a..8b9a99c13 100644
--- a/lib/ephy-file-helpers.h
+++ b/lib/ephy-file-helpers.h
@@ -1,5 +1,7 @@
/*
* Copyright (C) 2002 Jorn Baayen
+ * Copyright (C) 2003, 2004 Marco Pesenti Gritti
+ * Copyright (C) 2004 Christian Persch
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -25,6 +27,13 @@
G_BEGIN_DECLS
+typedef enum
+{
+ EPHY_MIME_PERMISSION_SAFE = 1,
+ EPHY_MIME_PERMISSION_UNSAFE = 2,
+ EPHY_MIME_PERMISSION_UNKNOWN = 3
+} EphyMimePermission;
+
const char *ephy_file (const char *filename);
const char *ephy_dot_dir (void);
@@ -53,6 +62,8 @@ gboolean ephy_file_switch_temp_file (const char *filename,
void ephy_file_delete_on_exit (const char *path);
+EphyMimePermission ephy_file_check_mime (const char *mime_type);
+
G_END_DECLS
#endif /* EPHY_FILE_HELPERS_H */