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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
|
#pragma once
#include <string>
#include <vector>
#include <vdr/plugin.h>
#include "flat.h"
#define PLUGINCONFIGPATH (cPlugin::ConfigDirectory(PLUGIN_NAME_I18N))
#define PLUGINRESOURCEPATH (cPlugin::ResourceDirectory(PLUGIN_NAME_I18N))
class cFlatConfig
{
private:
cString checkSlashAtEnd(std::string path);
int DecorCurrent;
public:
cFlatConfig(void);
~cFlatConfig(void);
void Init(void);
void SetLogoPath(cString path);
bool SetupParse(const char *Name, const char *Value);
void ThemeCheckAndInit(void);
void ThemeInit(void);
void DecorDescriptions(cStringList &Decors);
cString DecorDescription(cString File);
void DecorLoadFile(cString File);
void DecorLoadCurrent(void);
void DecorCheckAndInit(void);
void GetConfigFiles(cStringList &Files);
public:
cString ThemeCurrent;
cString logoPath;
cString iconPath;
// BORDER TYPES
// 0 = none
// 1 = rect
// 2 = round
// 3 = invert round
// 4 = rect + alpha blend
// 5 = round + alpha blend
// 6 = invert round + alpha blend
int decorBorderChannelByTheme;
int decorBorderChannelTypeTheme, decorBorderChannelSizeTheme;
int decorBorderChannelTypeUser, decorBorderChannelSizeUser;
int decorBorderChannelType, decorBorderChannelSize;
tColor decorBorderChannelFg, decorBorderChannelBg;
int decorBorderChannelEPGByTheme;
int decorBorderChannelEPGTypeTheme, decorBorderChannelEPGSizeTheme;
int decorBorderChannelEPGTypeUser, decorBorderChannelEPGSizeUser;
int decorBorderChannelEPGType, decorBorderChannelEPGSize;
tColor decorBorderChannelEPGFg, decorBorderChannelEPGBg;
int decorBorderTopBarByTheme;
int decorBorderTopBarTypeTheme, decorBorderTopBarSizeTheme;
int decorBorderTopBarTypeUser, decorBorderTopBarSizeUser;
int decorBorderTopBarType, decorBorderTopBarSize;
tColor decorBorderTopBarFg, decorBorderTopBarBg;
int decorBorderMessageByTheme;
int decorBorderMessageTypeTheme, decorBorderMessageSizeTheme;
int decorBorderMessageTypeUser, decorBorderMessageSizeUser;
int decorBorderMessageType, decorBorderMessageSize;
tColor decorBorderMessageFg, decorBorderMessageBg;
int decorBorderVolumeByTheme;
int decorBorderVolumeTypeTheme, decorBorderVolumeSizeTheme;
int decorBorderVolumeTypeUser, decorBorderVolumeSizeUser;
int decorBorderVolumeType, decorBorderVolumeSize;
tColor decorBorderVolumeFg, decorBorderVolumeBg;
int decorBorderTrackByTheme;
int decorBorderTrackTypeTheme, decorBorderTrackSizeTheme;
int decorBorderTrackTypeUser, decorBorderTrackSizeUser;
int decorBorderTrackType, decorBorderTrackSize;
tColor decorBorderTrackFg, decorBorderTrackBg;
tColor decorBorderTrackSelFg, decorBorderTrackSelBg;
tColor decorBorderTrackCurFg, decorBorderTrackCurBg;
int decorBorderReplayByTheme;
int decorBorderReplayTypeTheme, decorBorderReplaySizeTheme;
int decorBorderReplayTypeUser, decorBorderReplaySizeUser;
int decorBorderReplayType, decorBorderReplaySize;
tColor decorBorderReplayFg, decorBorderReplayBg;
int decorBorderMenuItemByTheme;
int decorBorderMenuItemTypeTheme, decorBorderMenuItemSizeTheme;
int decorBorderMenuItemTypeUser, decorBorderMenuItemSizeUser;
int decorBorderMenuItemType, decorBorderMenuItemSize;
tColor decorBorderMenuItemFg, decorBorderMenuItemBg;
tColor decorBorderMenuItemSelFg, decorBorderMenuItemSelBg;
tColor decorBorderMenuItemCurFg, decorBorderMenuItemCurBg;
int decorBorderMenuContentHeadByTheme;
int decorBorderMenuContentHeadTypeTheme, decorBorderMenuContentHeadSizeTheme;
int decorBorderMenuContentHeadTypeUser, decorBorderMenuContentHeadSizeUser;
int decorBorderMenuContentHeadType, decorBorderMenuContentHeadSize;
tColor decorBorderMenuContentHeadFg, decorBorderMenuContentHeadBg;
int decorBorderMenuContentByTheme;
int decorBorderMenuContentTypeTheme, decorBorderMenuContentSizeTheme;
int decorBorderMenuContentTypeUser, decorBorderMenuContentSizeUser;
int decorBorderMenuContentType, decorBorderMenuContentSize;
tColor decorBorderMenuContentFg, decorBorderMenuContentBg;
int decorBorderButtonByTheme;
int decorBorderButtonTypeTheme, decorBorderButtonSizeTheme;
int decorBorderButtonTypeUser, decorBorderButtonSizeUser;
int decorBorderButtonType, decorBorderButtonSize;
tColor decorBorderButtonFg, decorBorderButtonBg;
// PROGRESS TYPES
// 0 = small line + big line
// 1 = big line
// 2 = big line + outline
// 3 = small line + big line + dot
// 4 = big line + dot
// 5 = big line + outline + dot
// 6 = small line + dot
// 7 = outline + dot
// 8 = small line + big line + alpha blend
// 9 = big line + alpha blend
int decorProgressChannelByTheme;
int decorProgressChannelTypeTheme, decorProgressChannelSizeTheme;
int decorProgressChannelTypeUser, decorProgressChannelSizeUser;
int decorProgressChannelType, decorProgressChannelSize;
tColor decorProgressChannelFg, decorProgressChannelBarFg, decorProgressChannelBg;
int decorProgressVolumeByTheme;
int decorProgressVolumeTypeTheme, decorProgressVolumeSizeTheme;
int decorProgressVolumeTypeUser, decorProgressVolumeSizeUser;
int decorProgressVolumeType, decorProgressVolumeSize;
tColor decorProgressVolumeFg, decorProgressVolumeBarFg, decorProgressVolumeBg;
int decorProgressMenuItemByTheme;
int decorProgressMenuItemTypeTheme, decorProgressMenuItemSizeTheme;
int decorProgressMenuItemTypeUser, decorProgressMenuItemSizeUser;
int decorProgressMenuItemType, decorProgressMenuItemSize;
tColor decorProgressMenuItemFg, decorProgressMenuItemBarFg, decorProgressMenuItemBg;
tColor decorProgressMenuItemCurFg, decorProgressMenuItemCurBarFg, decorProgressMenuItemCurBg;
int decorProgressReplayByTheme;
int decorProgressReplayTypeTheme, decorProgressReplaySizeTheme;
int decorProgressReplayTypeUser, decorProgressReplaySizeUser;
int decorProgressReplayType, decorProgressReplaySize;
tColor decorProgressReplayFg, decorProgressReplayBarFg, decorProgressReplayBg;
int decorProgressSignalByTheme;
int decorProgressSignalTypeTheme, decorProgressSignalSizeTheme;
int decorProgressSignalTypeUser, decorProgressSignalSizeUser;
int decorProgressSignalType, decorProgressSignalSize;
tColor decorProgressSignalFg, decorProgressSignalBarFg, decorProgressSignalBg;
/* Types
* 0 = left line + rect bar
* 1 = left line + round bar
* 2 = middle line + rect bar
* 3 = middle line + round bar
* 4 = outline + rect bar
* 5 = outline + round bar
* 6 = rect bar
* 7 = round bar
*/
int decorScrollBarByTheme;
int decorScrollBarTypeTheme, decorScrollBarSizeTheme;
int decorScrollBarTypeUser, decorScrollBarSizeUser;
int decorScrollBarType, decorScrollBarSize;
tColor decorScrollBarFg, decorScrollBarBarFg, decorScrollBarBg;
// General Config
int ButtonsShowEmpty;
int ChannelIconsShow;
int SignalQualityShow;
int SignalQualityUseColors;
int DiskUsageShow;
int DiskUsageShort;
// 0 = occupied
// 1 = free
int DiskUsageFree;
int MenuItemPadding;
int marginOsdVer, marginOsdHor;
int MessageOffset;
int MenuContentFullSize;
double TopBarFontSize;
double TopBarFontClockScale;
int ChannelResolutionAspectShow;
int ChannelFormatShow;
int ChannelSimpleAspectFormat;
int ChannelBitrateShow;
int ChannelBitrateShowCalcInterval; // hidden config
int ChannelTimeLeft;
int RecordingResolutionAspectShow;
int RecordingFormatShow;
int RecordingSimpleAspectFormat;
int RecordingAdditionalInfoShow;
double TimeSecsScale;
int EpgRerunsShow;
int EpgAdditionalInfoShow;
int TopBarRecordingShow;
int TopBarRecConflictsShow;
int TopBarRecConflictsHigh;
int MenuItemIconsShow;
int TopBarMenuIconShow;
int TopBarHideClockText;
double MainMenuItemScale;
int MenuChannelView;
int MenuTimerView;
int MenuEventView;
int MenuRecordingView;
int MenuFullOsd;
// 0 = vertikal
// 1 = horizontal
int MessageColorPosition;
/* hidden configs (only in setup.conf, no osd menu) */
int MenuItemRecordingClearPercent;
int MenuItemRecordingShowFolderDate; // 0 = disable, 1 = newest recording date, 2 = oldest recording date
int MenuItemParseTilde;
/* hidden configs (only in setup.conf, no osd menu) */
// Text Scroller
int ScrollerEnable;
int ScrollerStep;
int ScrollerDelay;
int ScrollerType;
// TVScraper
int TVScraperChanInfoShowPoster;
double TVScraperChanInfoPosterSize;
int TVScraperEPGInfoShowPoster;
int TVScraperRecInfoShowPoster;
int TVScraperEPGInfoShowActors;
int TVScraperRecInfoShowActors;
int DecorIndex;
void Store(const char *Name, const char *Value, const char *Filename);
void Store(const char *Name, int Value, const char *Filename);
void Store(const char *Name, double &Value, const char *Filename);
};
|