X-Git-Url: https://www.fi.muni.cz/~kas/git//home/kas/public_html/git/?a=blobdiff_plain;f=properties%2Fev-properties-main.c;h=3b1e8e06eb3b490a03d55d26c6fa40fa21873cef;hb=c3d5029cc1ea491f3e1630ad6f6dde4762f2625d;hp=2e566d5505763b5397f4641f27f95162088434b5;hpb=13c49bea656a4f495e2c4baedab130eab367ae4f;p=evince.git diff --git a/properties/ev-properties-main.c b/properties/ev-properties-main.c index 2e566d55..3b1e8e06 100644 --- a/properties/ev-properties-main.c +++ b/properties/ev-properties-main.c @@ -83,34 +83,27 @@ ev_properties_get_pages (NautilusPropertyPageProvider *provider, GList *files) { GError *error = NULL; - char *mime; EvDocument *document; GList *pages = NULL; NautilusFileInfo *file; char *uri = NULL; GtkWidget *page, *label; NautilusPropertyPage *property_page; - + /* only add properties page if a single file is selected */ if (files == NULL || files->next != NULL) goto end; file = files->data; /* okay, make the page */ - mime = nautilus_file_info_get_mime_type (file); - document = ev_document_factory_get_document (mime); - g_free (mime); - - if (document == NULL) - goto end; - uri = nautilus_file_info_get_uri (file); - if (!ev_document_load (document, uri, &error)) { - if (error) { - g_error_free (error); - } + document = ev_document_factory_get_document (uri, &error); + + if (error) { + g_error_free (error); goto end; } + label = gtk_label_new (_("Document")); page = ev_properties_view_new (); ev_properties_view_set_info (EV_PROPERTIES_VIEW (page),