wlmaker
Loading...
Searching...
No Matches
desktop-parser.h
Go to the documentation of this file.
1/* ========================================================================= */
46#ifndef __WLMAKER_DESKTOP_PARSER_H__
47#define __WLMAKER_DESKTOP_PARSER_H__
48
49#include <libbase/libbase.h>
50#include <stdbool.h>
51#include <stdint.h>
52
53#ifdef __cplusplus
54extern "C" {
55#endif // __cplusplus
56
57struct desktop_parser;
58
61 DESKTOP_ENTRY_TYPE_UNKNOWN = 0,
62 DESKTOP_ENTRY_TYPE_APPLICATION = 1,
63 DESKTOP_ENTRY_TYPE_LINK = 2,
64 DESKTOP_ENTRY_TYPE_DIRECTORY = 3,
65};
66
71
73 bool hidden;
78
81
83 char *name_ptr;
85 char *exec_ptr;
89 char *path_ptr;
92};
93
102struct desktop_parser *desktop_parser_create(const char *locale_ptr);
103
109void desktop_parser_destroy(struct desktop_parser *parser);
110
121 const struct desktop_parser *parser,
122 const char *fname_ptr,
123 struct desktop_entry *entry_ptr);
124
135 const struct desktop_parser *parser,
136 const char *string_ptr,
137 struct desktop_entry *entry_ptr);
138
144void desktop_parser_entry_release(struct desktop_entry *entry_ptr);
145
147extern const bs_test_set_t desktop_parser_test_set;
148
149#ifdef __cplusplus
150} // extern "C"
151#endif // __cplusplus
152
153#endif // __WLMAKER_DESKTOP_PARSER_H__
154/* == End of desktop-parser.h ============================================== */
int desktop_parser_string_to_entry(const struct desktop_parser *parser, const char *string_ptr, struct desktop_entry *entry_ptr)
Definition desktop-parser.c:264
desktop_entry_type
Definition desktop-parser.h:60
void desktop_parser_entry_release(struct desktop_entry *entry_ptr)
Definition desktop-parser.c:276
int desktop_parser_file_to_entry(const struct desktop_parser *parser, const char *fname_ptr, struct desktop_entry *entry_ptr)
Definition desktop-parser.c:252
struct desktop_parser * desktop_parser_create(const char *locale_ptr)
Definition desktop-parser.c:192
void desktop_parser_destroy(struct desktop_parser *parser)
Definition desktop-parser.c:237
const bs_test_set_t desktop_parser_test_set
Definition desktop-parser.c:626
Definition desktop-parser.h:68
char * try_exec_ptr
Definition desktop-parser.h:87
char * exec_ptr
Definition desktop-parser.h:85
enum desktop_entry_type type
Definition desktop-parser.h:70
char * name_ptr
Definition desktop-parser.h:83
bool terminal
Definition desktop-parser.h:77
int8_t name_priority
Definition desktop-parser.h:80
bool no_display
Definition desktop-parser.h:75
char * path_ptr
Definition desktop-parser.h:89
bool hidden
Definition desktop-parser.h:73
char ** category_ptrs
Definition desktop-parser.h:91
Definition desktop-parser.c:62