1
/* vi:set et ai sw=2 sts=2 ts=2: */
3
* Copyright (c) 2009 Jannis Pohlmann <jannis@xfce.org>
5
* This program is free software; you can redistribute it and/or
6
* modify it under the terms of the GNU General Public License as
7
* published by the Free Software Foundation; either version 2 of
8
* the License, or (at your option) any later version.
10
* This program is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
* GNU General Public License for more details.
15
* You should have received a copy of the GNU General Public
16
* License along with this program; if not, write to the Free
17
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18
* Boston, MA 02110-1301, USA.
21
#ifndef __TUMBLER_REGISTRY_H__
22
#define __TUMBLER_REGISTRY_H__
24
#include <tumbler/tumbler.h>
28
#define TUMBLER_TYPE_REGISTRY (tumbler_registry_get_type ())
29
#define TUMBLER_REGISTRY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUMBLER_TYPE_REGISTRY, TumblerRegistry))
30
#define TUMBLER_REGISTRY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUMBLER_TYPE_REGISTRY, TumblerRegistryClass))
31
#define TUMBLER_IS_REGISTRY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUMBLER_TYPE_REGISTRY))
32
#define TUMBLER_IS_REGISTRY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUMBLER_TYPE_REGISTRY)
33
#define TUMBLER_REGISTRY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUMBLER_TYPE_REGISTRY, TumblerRegistryClass))
35
typedef struct _TumblerRegistryClass TumblerRegistryClass;
36
typedef struct _TumblerRegistry TumblerRegistry;
38
GType tumbler_registry_get_type (void) G_GNUC_CONST;
40
TumblerRegistry *tumbler_registry_new (void) G_GNUC_MALLOC G_GNUC_WARN_UNUSED_RESULT;
41
gboolean tumbler_registry_load (TumblerRegistry *registry,
43
void tumbler_registry_add (TumblerRegistry *registry,
44
TumblerThumbnailer *thumbnailer);
45
void tumbler_registry_remove (TumblerRegistry *registry,
46
TumblerThumbnailer *thumbnailer);
47
GList *tumbler_registry_get_thumbnailers (TumblerRegistry *registry) G_GNUC_MALLOC G_GNUC_WARN_UNUSED_RESULT;
48
TumblerThumbnailer **tumbler_registry_get_thumbnailer_array (TumblerRegistry *registry,
49
TumblerFileInfo **infos,
50
guint length) G_GNUC_MALLOC G_GNUC_WARN_UNUSED_RESULT;
51
void tumbler_registry_update_supported (TumblerRegistry *registry);
52
void tumbler_registry_get_supported (TumblerRegistry *registry,
53
const gchar *const **uri_schemes,
54
const gchar *const **mime_types);
55
TumblerThumbnailer *tumbler_registry_get_preferred (TumblerRegistry *registry,
56
const gchar *hash_key) G_GNUC_WARN_UNUSED_RESULT;
57
void tumbler_registry_set_preferred (TumblerRegistry *registry,
58
const gchar *hash_key,
59
TumblerThumbnailer *thumbnailer);
63
#endif /* !__TUMBLER_REGISTRY_H__ */