X-Git-Url: https://www.fi.muni.cz/~kas/git//home/kas/public_html/git/?a=blobdiff_plain;f=libdocument%2Fev-backends-manager.c;h=505d5c4d102f0adfbdf9bf048d39aeba648e4143;hb=f343927df4325959193353c52cff1ea4b20b2286;hp=87f7fea414ae489d1e6222612beb5d32b2fabc3e;hpb=b490fff8a6c6ab7bb23cc0f274e3150e7ab4471d;p=evince.git diff --git a/libdocument/ev-backends-manager.c b/libdocument/ev-backends-manager.c index 87f7fea4..505d5c4d 100644 --- a/libdocument/ev-backends-manager.c +++ b/libdocument/ev-backends-manager.c @@ -30,6 +30,7 @@ typedef struct _EvBackendInfo EvBackendInfo; struct _EvBackendInfo { gchar *module_name; GTypeModule *module; + gboolean resident; GType type_id; @@ -78,6 +79,9 @@ ev_backends_manager_load_backend (const gchar *file) return NULL; } + info->resident = g_key_file_get_boolean (backend_file, EV_BACKENDS_GROUP, + "Resident", NULL); + info->type_desc = g_key_file_get_locale_string (backend_file, EV_BACKENDS_GROUP, "TypeDescription", NULL, NULL); if (!info->type_desc) { @@ -114,7 +118,7 @@ ev_backends_manager_load (void) dir = g_dir_open (EV_BACKENDSDIR, 0, &error); if (!dir) { - g_warning (error->message); + g_warning ("%s", error->message); g_error_free (error); return FALSE; @@ -194,7 +198,7 @@ ev_backends_manager_get_document (const gchar *mime_type) gchar *path; path = g_module_build_path (EV_BACKENDSDIR, info->module_name); - info->module = G_TYPE_MODULE (ev_module_new (path)); + info->module = G_TYPE_MODULE (ev_module_new (path, info->resident)); g_free (path); }