Commit 6004dc8e authored by Michael J. Chudobiak's avatar Michael J. Chudobiak
Browse files

added the parse name (gth::file::full-name) to metadata, bug 602962

parent ac9f42ff
......@@ -42,6 +42,7 @@ GthMetadataInfo file_metadata_info[] = {
{ "gth::file::display-mtime", N_("Modified"), "file", 3, GTH_METADATA_ALLOW_EVERYWHERE },
{ "standard::fast-content-type", N_("Type"), "file", 4, GTH_METADATA_ALLOW_EVERYWHERE },
{ "gth::file::is-modified", NULL, "file", 5, GTH_METADATA_ALLOW_NOWHERE },
{ "gth::file::full-name", N_("Full Name"), "file", 6, GTH_METADATA_ALLOW_EVERYWHERE },
{ "general::size", N_("Dimensions"), "general", 10, GTH_METADATA_ALLOW_EVERYWHERE },
{ "general::duration", N_("Duration"), "general", 11, GTH_METADATA_ALLOW_EVERYWHERE },
......
......@@ -60,6 +60,10 @@ gth_metadata_provider_file_read (GthMetadataProvider *self,
g_file_info_set_attribute_string (file_data->info, "gth::file::display-mtime", value);
g_free (value);
value = g_file_get_parse_name (file_data->file);
g_file_info_set_attribute_string (file_data->info, "gth::file::full-name", value);
g_free (value);
value_s = get_static_string (g_file_info_get_content_type (file_data->info));
if (value_s != NULL)
g_file_info_set_attribute_string (file_data->info, "gth::file::content-type", value_s);
......@@ -92,7 +96,7 @@ gth_metadata_provider_constructor (GType type,
obj = parent_class->constructor (type, n_construct_properties, construct_properties);
self = GTH_METADATA_PROVIDER (obj);
g_object_set (self, "readable-attributes", "gth::file::display-size,gth::file::display-mtime,gth::file::content-type,gth::file::is-modified", NULL);
g_object_set (self, "readable-attributes", "gth::file::display-size,gth::file::display-mtime,gth::file::content-type,gth::file::is-modified,gth::file::full-name", NULL);
return obj;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment