imgstore.h
Go to the documentation of this file.
1 
7 /* purple
8  *
9  * Purple is the legal property of its developers, whose names are too numerous
10  * to list here. Please refer to the COPYRIGHT file distributed with this
11  * source distribution.
12  *
13  * This program is free software; you can redistribute it and/or modify
14  * it under the terms of the GNU General Public License as published by
15  * the Free Software Foundation; either version 2 of the License, or
16  * (at your option) any later version.
17  *
18  * This program is distributed in the hope that it will be useful,
19  * but WITHOUT ANY WARRANTY; without even the implied warranty of
20  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21  * GNU General Public License for more details.
22  *
23  * You should have received a copy of the GNU General Public License
24  * along with this program; if not, write to the Free Software
25  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
26  */
27 #ifndef _PURPLE_IMGSTORE_H_
28 #define _PURPLE_IMGSTORE_H_
29 
30 #include <glib.h>
31 
37 typedef struct _PurpleStoredImage PurpleStoredImage;
38 
39 #ifdef __cplusplus
40 extern "C" {
41 #endif
42 
67 purple_imgstore_add(gpointer data, size_t size, const char *filename);
68 
88 purple_imgstore_new_from_file(const char *path);
89 
112 int purple_imgstore_add_with_id(gpointer data, size_t size, const char *filename);
113 
123 
132 gconstpointer purple_imgstore_get_data(PurpleStoredImage *img);
133 
143 
152 const char *purple_imgstore_get_filename(const PurpleStoredImage *img);
153 
164 
174 
186 
196 void purple_imgstore_ref_by_id(int id);
197 
207 void purple_imgstore_unref_by_id(int id);
208 
214 void *purple_imgstore_get_handle(void);
215 
219 void purple_imgstore_init(void);
220 
224 void purple_imgstore_uninit(void);
225 
226 #ifdef __cplusplus
227 }
228 #endif
229 
230 #endif /* _PURPLE_IMGSTORE_H_ */