]> www.fi.muni.cz Git - evince.git/blobdiff - shell/ev-metadata.c
[l10n]Fixes on Catalan translation
[evince.git] / shell / ev-metadata.c
index 4db4a0089e6c13267eb69dc0e7ee6fba7ed994fc..3a0eefabb1abe82947b5da94b4ff78022b085072 100644 (file)
@@ -15,7 +15,7 @@
  *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  */
 
 #include <gio/gio.h>
@@ -89,13 +89,11 @@ ev_metadata_load (EvMetadata *metadata)
                return;
        }
 
-#if GLIB_CHECK_VERSION(2,22,0)
        if (!g_file_info_has_namespace (info, "metadata")) {
                g_object_unref (info);
 
                return;
        }
-#endif
 
        attrs = g_file_info_list_attributes (info, "metadata");
        for (i = 0; attrs[i]; i++) {
@@ -138,6 +136,12 @@ ev_metadata_new (GFile *file)
        return metadata;
 }
 
+gboolean
+ev_metadata_is_empty (EvMetadata *metadata)
+{
+       return g_hash_table_size (metadata->items) == 0;
+}
+
 gboolean
 ev_metadata_get_string (EvMetadata  *metadata,
                        const gchar *key,