blob: 18d6cf2c3ff17a1235ea3a21c48ad457a8847dcd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
#ifndef _DB_H_
#define _DB_H_
#include <glib.h>
#include <sqlite3.h>
struct directory_t {
gchar *name;
sqlite_uint64 dirid;
};
struct wallpaper_t {
gchar *filepath;
sqlite_uint64 id;
int size;
int width;
int height;
};
int db_open();
void db_close();
sqlite_uint64 db_add_directory(const char*, sqlite_uint64);
sqlite_uint64 db_get_directory(const char*);
int db_get_top_level_directories(GArray**);
int db_get_directories(sqlite_uint64, GArray**);
sqlite_uint64 db_add_wallpaper(const char*, sqlite_uint64, int, int, int);
sqlite_uint64 db_get_wallpaper(const char*);
int db_get_wallpapers(sqlite_uint64, GArray**);
#endif
|