X-Git-Url: https://www.fi.muni.cz/~kas/git//home/kas/public_html/git/?a=blobdiff_plain;f=thumbnailer%2Fevince-thumbnailer.c;h=8960f18065ff9bad665ebaed9a6bcfd8e2c3b1dc;hb=1d26c7c94ab8b6102c8e426b5174dd001fff53fb;hp=d55067427bb292e9ae50f12ac7da95c268e72136;hpb=31e16bd8f386dc292e60489d4a17227804bdc2e6;p=evince.git diff --git a/thumbnailer/evince-thumbnailer.c b/thumbnailer/evince-thumbnailer.c index d5506742..8960f180 100644 --- a/thumbnailer/evince-thumbnailer.c +++ b/thumbnailer/evince-thumbnailer.c @@ -16,11 +16,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include -#include -#include -#include -#include +#include #include #include @@ -28,6 +24,8 @@ #include #include +#include + #include #include @@ -137,6 +135,7 @@ main (int argc, char *argv[]) const char *output; int size; char *uri; + GFile *file; if (argc <= 2 || argc > 5 || strcmp (argv[1], "-h") == 0 || strcmp (argv[1], "--help") == 0) { @@ -159,15 +158,18 @@ main (int argc, char *argv[]) return -1; } + g_type_init (); + if (!g_thread_supported ()) g_thread_init (NULL); - - gnome_vfs_init (); ev_backends_manager_init (); - uri = gnome_vfs_make_uri_from_shell_arg (input); + file = g_file_new_for_commandline_arg (input); + uri = g_file_get_uri (file); document = evince_thumbnailer_get_document (uri); + + g_object_unref (file); g_free (uri); if (!document) {