| 26 | static GhbValue *resources; |
| 27 | |
| 28 | void |
| 29 | ghb_resource_init (void) |
| 30 | { |
| 31 | GhbValue *val; |
| 32 | gsize data_size; |
| 33 | GBytes *gbytes; |
| 34 | gconstpointer data; |
| 35 | |
| 36 | resources = ghb_dict_new(); |
| 37 | |
| 38 | GResource *data_res = ghb_data_get_resource(); |
| 39 | |
| 40 | gbytes = g_resource_lookup_data(data_res, |
| 41 | "/fr/handbrake/ghb/data/internal_defaults.json", 0, NULL); |
| 42 | data = g_bytes_get_data(gbytes, &data_size); |
| 43 | val = ghb_json_parse(data); |
| 44 | g_bytes_unref(gbytes); |
| 45 | ghb_dict_set(resources, "internal-defaults", val); |
| 46 | } |
| 47 | |
| 48 | GhbValue* |
| 49 | ghb_resource_get(const gchar *name) |
no outgoing calls
no test coverage detected