src/linkapp.cpp |
73 | 73 | #ifdef HAVE_LIBOPK |
74 | 74 | isOPK = opk; |
75 | 75 | if (opk) { |
76 | | struct ParserData *pdata = openMetadata(linkfile); |
| 76 | struct ParserData *pdata = opk_open(linkfile); |
77 | 77 | char *param; |
78 | 78 | if (!pdata) { |
79 | 79 | ERROR("Unable to initialize libopk\n"); |
... | ... | |
82 | 82 | |
83 | 83 | file = linkfile; |
84 | 84 | |
85 | | param = readParam(pdata, "Name"); |
| 85 | param = opk_read_param(pdata, "Name"); |
86 | 86 | if (!param) |
87 | 87 | ERROR("Missing \"Name\" parameter\n"); |
88 | 88 | else |
89 | 89 | title = param; |
90 | 90 | |
91 | | param = readParam(pdata, "Comment"); |
| 91 | param = opk_read_param(pdata, "Comment"); |
92 | 92 | if (param) |
93 | 93 | description = param; |
94 | 94 | |
95 | 95 | /* Read the icon from the OPK only |
96 | 96 | * if it doesn't exist on the skin */ |
97 | | param = readParam(pdata, "Icon"); |
| 97 | param = opk_read_param(pdata, "Icon"); |
98 | 98 | if (param) { |
99 | 99 | this->icon = gmenu2x->sc.getSkinFilePath((string) param + ".png"); |
100 | 100 | if (this->icon.empty()) |
... | ... | |
105 | 105 | if (iconPath.empty()) |
106 | 106 | searchIcon(); |
107 | 107 | |
108 | | param = readParam(pdata, "Exec"); |
| 108 | param = opk_read_param(pdata, "Exec"); |
109 | 109 | if (!param) |
110 | 110 | ERROR("Missing \"Exec\" parameter\n"); |
111 | 111 | else |
112 | 112 | exec = param; |
113 | 113 | |
114 | 114 | #ifdef PLATFORM_DINGUX |
115 | | param = readParam(pdata, "Terminal"); |
| 115 | param = opk_read_param(pdata, "Terminal"); |
116 | 116 | if (param) |
117 | 117 | consoleApp = !strcmp(param, "true"); |
118 | 118 | #endif |
119 | 119 | |
120 | | param = readParam(pdata, "X-OD-Manual"); |
| 120 | param = opk_read_param(pdata, "X-OD-Manual"); |
121 | 121 | if (param) |
122 | 122 | manual = param; |
123 | 123 | |
124 | | param = readParam(pdata, "X-OD-Daemon"); |
| 124 | param = opk_read_param(pdata, "X-OD-Daemon"); |
125 | 125 | if (param) |
126 | 126 | dontleave = !strcmp(param, "true"); |
127 | 127 | |
128 | 128 | edited = false; |
129 | | closeMetadata(pdata); |
| 129 | opk_close(pdata); |
130 | 130 | } |
131 | 131 | #endif /* HAVE_LIBOPK */ |
132 | 132 | |