source: titan/titan/adjust.h @ 44440

Last change on this file since 44440 was 44440, checked in by obi, 3 years ago

enable debug level on adjust

File size: 24.4 KB
Line 
1#ifndef ADJUST_H
2#define ADJUST_H
3
4void screenadjust()
5{
6        int rcret = 0;
7        char* tmpstr = NULL;
8        char* ret = NULL;
9
10        struct skin* adjust = getscreen("adjust");
11        struct skin* listbox = getscreennode(adjust, "listbox");
12        struct skin* volbartimeout = getscreennode(adjust, "volbartimeout");
13        struct skin* infobartimeout = getscreennode(adjust, "infobartimeout");
14        struct skin* infobarsleep = getscreennode(adjust, "infobarsleep");
15        struct skin* secondinfobar = getscreennode(adjust, "secondinfobar");
16        struct skin* spinnerspeed = getscreennode(adjust, "spinnerspeed");
17        struct skin* spinnertime = getscreennode(adjust, "spinnertime");
18        struct skin* hangtime = getscreennode(adjust, "hangtime");
19        struct skin* nozapclear = getscreennode(adjust, "nozapclear");
20        struct skin* fastzap = getscreennode(adjust, "fastzap");
21        struct skin* faststop = getscreennode(adjust, "faststop");
22        struct skin* dirsort = getscreennode(adjust, "dirsort");
23        struct skin* poweraktion = getscreennode(adjust, "poweraktion");
24        struct skin* frontpoweraktion = getscreennode(adjust, "frontpoweraktion");
25        struct skin* virtualzap = getscreennode(adjust, "virtualzap");
26        struct skin* fasttextrender = getscreennode(adjust, "fasttextrender");
27        struct skin* recsplitsize = getscreennode(adjust, "recsplitsize");
28        struct skin* recforerun = getscreennode(adjust, "recforerun");
29        struct skin* recoverrun = getscreennode(adjust, "recoverrun");
30        struct skin* skip13 = getscreennode(adjust, "skip13");
31        struct skin* skip46 = getscreennode(adjust, "skip46");
32        struct skin* skip79 = getscreennode(adjust, "skip79");
33        struct skin* playertype = getscreennode(adjust, "playertype");
34        struct skin* autochangechannelname = getscreennode(adjust, "autochangechannelname");
35        struct skin* def_rectimer_after = getscreennode(adjust, "def_rectimer_after");
36        struct skin* showchanneltimeline = getscreennode(adjust, "showchanneltimeline");
37        struct skin* screenanim = getscreennode(adjust, "screenanim");
38        struct skin* screenanimspeed = getscreennode(adjust, "screenanimspeed");
39        struct skin* channellistview = getscreennode(adjust, "channellistview");
40        struct skin* showlastpos = getscreennode(adjust, "showlastpos");
41        struct skin* recsync = getscreennode(adjust, "recsync");
42        struct skin* recordnamefmt = getscreennode(adjust, "recordnamefmt");
43        struct skin* newsletter = getscreennode(adjust, "newsletter");
44        struct skin* showhiddenfiles = getscreennode(adjust, "showhiddenfiles");
45        struct skin* expertmodus = getscreennode(adjust, "expertmodus");
46        struct skin* infobarprogram = getscreennode(adjust, "infobarprogram");
47        struct skin* crosscontrol = getscreennode(adjust, "crosscontrol");
48        struct skin* emucontrol = getscreennode(adjust, "emucontrol");
49        struct skin* usecec = getscreennode(adjust, "usecec");
50        struct skin* playerbuffersize = getscreennode(adjust, "playerbuffersize");
51        struct skin* playerbufferseektime = getscreennode(adjust, "playerbufferseektime");
52        struct skin* sataswitch = getscreennode(adjust, "sataswitch");
53        struct skin* dualboot = getscreennode(adjust, "dualboot");
54        struct skin* community_user = getscreennode(adjust, "community_user");
55        struct skin* community_pass = getscreennode(adjust, "community_pass");
56        struct skin* debuglevel = getscreennode(adjust, "debuglevel");
57        struct skin* zapmode = getscreennode(adjust, "zapmode");
58
59
60        struct skin* tmp = NULL;
61
62        changeinput(volbartimeout, "1\n2\n3\n4\n5\n6\n7\n8\n9\n10");
63        setchoiceboxselection(volbartimeout, getconfig("volbartimeout", NULL));
64
65        changeinput(infobartimeout, "1\n2\n3\n4\n5\n6\n7\n8\n9\n10\n20\n30\n60\n10000");
66        setchoiceboxselection(infobartimeout, getconfig("infobartimeout", NULL));
67
68        changeinput(infobarsleep, "0\n1\n2\n3\n4\n5");
69        setchoiceboxselection(infobarsleep, getconfig("infobarsleep", NULL));
70
71        addchoicebox(secondinfobar, "0", _("no"));
72        addchoicebox(secondinfobar, "1", _("infobar"));
73        addchoicebox(secondinfobar, "2", _("EPG"));
74        addchoicebox(secondinfobar, "3", _("Channel EPG"));
75        setchoiceboxselection(secondinfobar, getconfig("secondinfobar", NULL));
76
77        changeinput(spinnerspeed, "1\n3\n9\n12\n15\n18\n21\n24\n27\n30");
78        setchoiceboxselection(spinnerspeed, getconfig("spinnerspeed", NULL));
79
80        changeinput(spinnertime, "1\n2\n3\n4\n5\n6\n7\n8\n10000");
81        setchoiceboxselection(spinnertime, getconfig("spinnertime", NULL));
82
83        changeinput(hangtime, "5\n10\n15\n30\n60\n120\n10000");
84        setchoiceboxselection(hangtime, getconfig("hangtime", NULL));
85
86        addchoicebox(nozapclear, "0", _("no"));
87        addchoicebox(nozapclear, "1", _("yes"));
88        setchoiceboxselection(nozapclear, getconfig("nozapclear", NULL));
89
90        if(checkbox("ATEMIO7600") == 1 || vubox1 == 1)
91                fastzap->hidden = YES;
92        else
93                fastzap->hidden = NO;
94
95        addchoicebox(fastzap, "0", _("no"));
96        addchoicebox(fastzap, "2", _("medium"));
97        addchoicebox(fastzap, "1", _("fast"));
98        setchoiceboxselection(fastzap, getconfig("fastzap", NULL));
99
100        addchoicebox(faststop, "0", _("no"));
101        addchoicebox(faststop, "1", _("yes"));
102        setchoiceboxselection(faststop, getconfig("faststop", NULL));
103
104        addchoicebox(dirsort, "0", _("alpha"));
105        addchoicebox(dirsort, "1", _("reverse alpha"));
106        addchoicebox(dirsort, "2", _("size"));
107        addchoicebox(dirsort, "3", _("reverse size"));
108        addchoicebox(dirsort, "4", _("date"));
109        addchoicebox(dirsort, "5", _("reverse date"));
110        setchoiceboxselection(dirsort, getconfig("dirsort", NULL));
111
112        addchoicebox(poweraktion, "0", _("Power Menu"));
113        addchoicebox(poweraktion, "1", _("Power Off"));
114        addchoicebox(poweraktion, "2", _("Standby"));
115        addchoicebox(poweraktion, "3", _("Restart"));
116        addchoicebox(poweraktion, "4", _("GUI Restart"));
117        setchoiceboxselection(poweraktion, getconfig("poweraktion", NULL));
118
119        addchoicebox(frontpoweraktion, "1", _("Power Off"));
120        addchoicebox(frontpoweraktion, "2", _("Standby"));
121        setchoiceboxselection(frontpoweraktion, getconfig("frontpoweraktion", NULL));
122
123        addchoicebox(virtualzap, "0", _("disable"));
124        addchoicebox(virtualzap, "1", _("1 sec"));
125        addchoicebox(virtualzap, "2", _("2 sec"));
126        addchoicebox(virtualzap, "9999", _("endless"));
127        setchoiceboxselection(virtualzap, getconfig("virtualzap", NULL));
128
129        addchoicebox(fasttextrender, "0", _("no"));
130        addchoicebox(fasttextrender, "1", _("yes"));
131        setchoiceboxselection(fasttextrender, getconfig("fasttextrender", NULL));
132
133        addchoicebox(recsplitsize, "0", _("disable"));
134        addchoicebox(recsplitsize, "1", _("1 GB"));
135        addchoicebox(recsplitsize, "2", _("2 GB"));
136        addchoicebox(recsplitsize, "3", _("3 GB"));
137        addchoicebox(recsplitsize, "4", _("4 GB"));
138        setchoiceboxselection(recsplitsize, getconfig("recsplitsize", NULL));
139
140        changeinput(recforerun, "0\n1\n2\n3\n4\n5\n6\n7\n8\n9\n10\n15\n20\n25\n30\n35\n40\n45\n50\n55\n60");
141        setchoiceboxselection(recforerun, getconfig("recforerun", NULL));
142
143        changeinput(recoverrun, "0\n1\n2\n3\n4\n5\n6\n7\n8\n9\n10\n15\n20\n25\n30\n35\n40\n45\n50\n55\n60");
144        setchoiceboxselection(recoverrun, getconfig("recoverrun", NULL));
145
146        changeinput(skip13, "15\n20\n30\n45\n60\n90\n120\n180\n300\n600\n900\n1200");
147        setchoiceboxselection(skip13, getconfig("skip13", NULL));
148
149        changeinput(skip46, "15\n20\n30\n45\n60\n90\n120\n180\n300\n600\n900\n1200");
150        setchoiceboxselection(skip46, getconfig("skip46", NULL));
151
152        changeinput(skip79, "15\n20\n30\n45\n60\n90\n120\n180\n300\n600\n900\n1200");
153        setchoiceboxselection(skip79, getconfig("skip79", NULL));
154
155        addchoicebox(playertype, "0", _("extern"));
156        addchoicebox(playertype, "1", _("intern"));
157        setchoiceboxselection(playertype, getconfig("playertype", NULL));
158
159        addchoicebox(autochangechannelname, "0", _("no"));
160        addchoicebox(autochangechannelname, "1", _("yes"));
161        setchoiceboxselection(autochangechannelname, getconfig("autochangechannelname", NULL));
162
163        addchoicebox(def_rectimer_after, "0", _("auto"));
164        addchoicebox(def_rectimer_after, "1", _("nothing"));
165        addchoicebox(def_rectimer_after, "2", _("standby"));
166        addchoicebox(def_rectimer_after, "3", _("power off"));
167        setchoiceboxselection(def_rectimer_after, getconfig("def_rectimer_after", NULL));
168
169        addchoicebox(showchanneltimeline, "0", _("no"));
170        addchoicebox(showchanneltimeline, "1", _("yes"));
171        setchoiceboxselection(showchanneltimeline, getconfig("showchanneltimeline", NULL));
172
173        addchoicebox(screenanim, "0", _("no"));
174        addchoicebox(screenanim, "1", _("anim. width"));
175        addchoicebox(screenanim, "2", _("anim. height"));
176        addchoicebox(screenanim, "3", _("anim. both"));
177#ifdef MIPSEL
178        addchoicebox(screenanim, "4", _("left to right"));
179        addchoicebox(screenanim, "5", _("top to bottom"));
180        if(checkbox("DM7020HD") == 1 || checkbox("DM7020HDV2") == 1 || checkbox("DM900") == 1 || checkbox("DM920") == 1 || checkbox("DM520") == 1 || checkbox("DM525") == 1)
181        {
182                addchoicebox(screenanim, "11", _("slide from left"));
183                addchoicebox(screenanim, "12", _("slide from bottom"));
184        }
185#endif
186        setchoiceboxselection(screenanim, getconfig("screenanim", NULL));
187
188        addchoicebox(screenanimspeed, "1", _("very fast"));
189        addchoicebox(screenanimspeed, "5", _("fast"));
190        addchoicebox(screenanimspeed, "10", _("normal"));
191        addchoicebox(screenanimspeed, "15", _("slow"));
192        addchoicebox(screenanimspeed, "20", _("very slow"));
193        setchoiceboxselection(screenanimspeed, getconfig("screenanimspeed", NULL));
194
195        addchoicebox(channellistview, "0", _("hidden"));
196        addchoicebox(channellistview, "1", _("show"));
197        setchoiceboxselection(channellistview, getconfig("channellistview", NULL));
198
199        addchoicebox(showlastpos, "0", _("no"));
200        addchoicebox(showlastpos, "1", _("yes"));
201        setchoiceboxselection(showlastpos, getconfig("showlastpos", NULL));
202
203        addchoicebox(recsync, "0", _("no"));
204        addchoicebox(recsync, "1", _("yes"));
205        setchoiceboxselection(recsync, getconfig("recsync", NULL));
206
207        addchoicebox(recordnamefmt, "0", _("channel-movie"));
208        addchoicebox(recordnamefmt, "1", _("movie-channel"));
209        setchoiceboxselection(recordnamefmt, getconfig("recordnamefmt", NULL));
210
211        addchoicebox(newsletter, "0", _("no"));
212        addchoicebox(newsletter, "1", _("yes"));
213        setchoiceboxselection(newsletter, getconfig("newsletter", NULL));
214
215        addchoicebox(showhiddenfiles, "0", _("no"));
216        addchoicebox(showhiddenfiles, "1", _("yes"));
217        setchoiceboxselection(showhiddenfiles, getconfig("showhiddenfiles", NULL));
218
219        addchoicebox(expertmodus, "0", _("no"));
220        addchoicebox(expertmodus, "10", _("yes"));
221        if(getconfigint("expertmodus", NULL) == 11)
222                addchoicebox(expertmodus, "11", _("expert (11)"));
223        setchoiceboxselection(expertmodus, getconfig("expertmodus", NULL));
224
225        addchoicebox(infobarprogram, "0", _("no"));
226        addchoicebox(infobarprogram, "1", _("yes"));
227        setchoiceboxselection(infobarprogram, getconfig("infobarprogram", NULL));
228
229        addchoicebox(crosscontrol, "0", _("no"));
230        addchoicebox(crosscontrol, "1", _("yes"));
231        addchoicebox(crosscontrol, "2", _("yes / vzap 1 sec"));
232        addchoicebox(crosscontrol, "3", _("yes / vzap 2 sec"));
233        addchoicebox(crosscontrol, "9999", _("yes / vzap endless"));
234        setchoiceboxselection(crosscontrol, getconfig("crosscontrol", NULL));
235
236        addchoicebox(emucontrol, "0", _("no"));
237        addchoicebox(emucontrol, "1", _("yes"));
238        setchoiceboxselection(emucontrol, getconfig("emucontrol", NULL));
239
240        addchoicebox(usecec, "0", _("no"));
241        addchoicebox(usecec, "1", _("yes"));
242        setchoiceboxselection(usecec, getconfig("usecec", NULL));
243
244        if(!file_exist("/mnt/config/dualboot"))
245        {
246                addchoicebox(dualboot, "0", _("no"));
247                addchoicebox(dualboot, "1", _("yes"));
248        }
249        else
250        {
251                addchoicebox(dualboot, "1", _("yes"));
252                addchoicebox(dualboot, "0", _("no"));
253        }
254        setchoiceboxselection(dualboot, getconfig("dualboot", NULL));
255
256        changemask(community_user, "****");
257        if(getconfig("community_user", NULL) == NULL)
258                changeinput(community_user, getconfig("community_user", NULL));
259        else
260                changeinput(community_pass, "****");
261
262        changemask(community_pass, "****");
263        if(getconfig("community_pass", NULL) == NULL)
264                changeinput(community_pass, getconfig("community_pass", NULL));
265        else
266                changeinput(community_pass, "****");
267
268//      if(file_exist("/proc/stb/video/zapmode") || file_exist("/proc/stb/video/zapping_mode"))
269        if(file_exist(getconfig("zapmodedev", NULL)))
270        {
271                addchoicebox(zapmode, "mute", _("Black screen"));
272                addchoicebox(zapmode, "hold", _("Hold screen"));
273                addchoicebox(zapmode, "mutetilllock", _("Black screen till locked"));
274                addchoicebox(zapmode, "holdtilllock", _("Hold till locked"));
275                ret = getzapmode();
276                setchoiceboxselection(zapmode, ret);
277                free(ret); ret = NULL;
278        }
279        else
280                zapmode->hidden = YES;
281
282// setdebuglevel
283//#ifndef BETA
284//      debuglevel->hidden = YES;
285//#else
286        tmpstr = ostrcat("10 - ", _("Minimal"), 0, 0);
287        addchoicebox(debuglevel, "10", tmpstr);
288        free(tmpstr), tmpstr = NULL;
289
290        tmpstr = ostrcat("40 - ", _("MTD Operation/System Update"), 0, 0);
291        addchoicebox(debuglevel, "40", tmpstr);
292        free(tmpstr), tmpstr = NULL;
293
294        tmpstr = ostrcat("50 - ", _("MediaCenter"), 0, 0);
295        addchoicebox(debuglevel, "50", tmpstr);
296        free(tmpstr), tmpstr = NULL;
297
298        tmpstr = ostrcat("55 - ", _("Network Interface"), 0, 0);
299        addchoicebox(debuglevel, "55", tmpstr);
300        free(tmpstr), tmpstr = NULL;
301
302        tmpstr = ostrcat("60 - ", _("Key Actions"), 0, 0);
303        addchoicebox(debuglevel, "60", tmpstr);
304        free(tmpstr), tmpstr = NULL;
305
306        tmpstr = ostrcat("70 - ", _("Networkbrowser"), 0, 0);
307        addchoicebox(debuglevel, "70", tmpstr);
308        free(tmpstr), tmpstr = NULL;
309
310        tmpstr = ostrcat("77 - ", _("Web Adjust"), 0, 0);
311        addchoicebox(debuglevel, "77", tmpstr);
312        free(tmpstr), tmpstr = NULL;
313
314        tmpstr = ostrcat("80 - ", _("Harddisk"), 0, 0);
315        addchoicebox(debuglevel, "80", tmpstr);
316        free(tmpstr), tmpstr = NULL;
317
318        tmpstr = ostrcat("81 - ", _("MultiImage"), 0, 0);
319        addchoicebox(debuglevel, "81", tmpstr);
320        free(tmpstr), tmpstr = NULL;
321
322        tmpstr = ostrcat("88 - ", _("Tithek"), 0, 0);
323        addchoicebox(debuglevel, "88", tmpstr);
324        free(tmpstr), tmpstr = NULL;
325
326        tmpstr = ostrcat("90 - ", _("Screensaver"), 0, 0);
327        addchoicebox(debuglevel, "90", tmpstr);
328        free(tmpstr), tmpstr = NULL;
329
330        tmpstr = ostrcat("99 - ", _("HTTP Header/Community"), 0, 0);
331        addchoicebox(debuglevel, "99", tmpstr);
332        free(tmpstr), tmpstr = NULL;
333
334        tmpstr = ostrcat("100 - ", _("Global"), 0, 0);
335        addchoicebox(debuglevel, "100", tmpstr);
336        free(tmpstr), tmpstr = NULL;
337
338        tmpstr = ostrcat("110 - ", _("Stringconvert"), 0, 0);
339        addchoicebox(debuglevel, "110", tmpstr);
340        free(tmpstr), tmpstr = NULL;
341
342        tmpstr = ostrcat("130 - ", _("TPK"), 0, 0);
343        addchoicebox(debuglevel, "130", tmpstr);
344        free(tmpstr), tmpstr = NULL;
345
346        tmpstr = ostrcat("133 - ", _("MediaDB/IMDb/TMDb"), 0, 0);
347        addchoicebox(debuglevel, "133", tmpstr);
348        free(tmpstr), tmpstr = NULL;
349
350        tmpstr = ostrcat("150 - ", _("ePlayer"), 0, 0);
351        addchoicebox(debuglevel, "150", tmpstr);
352        free(tmpstr), tmpstr = NULL;
353
354        tmpstr = ostrcat("200 - ", _("DVB Devices"), 0, 0);
355        addchoicebox(debuglevel, "200", tmpstr);
356        free(tmpstr), tmpstr = NULL;
357
358        tmpstr = ostrcat("201 - ", _("CA Device"), 0, 0);
359        addchoicebox(debuglevel, "201", tmpstr);
360        free(tmpstr), tmpstr = NULL;
361
362        tmpstr = ostrcat("250 - ", _("HTTP Server/Stream/Record"), 0, 0);
363        addchoicebox(debuglevel, "250", tmpstr);
364        free(tmpstr), tmpstr = NULL;
365
366        tmpstr = ostrcat("270 - ", _("Radiotext"), 0, 0);
367        addchoicebox(debuglevel, "270", tmpstr);
368        free(tmpstr), tmpstr = NULL;
369
370        tmpstr = ostrcat("278 - ", _("ID3"), 0, 0);
371        addchoicebox(debuglevel, "278", tmpstr);
372        free(tmpstr), tmpstr = NULL;
373
374        tmpstr = ostrcat("300 - ", _("Subtitle"), 0, 0);
375        addchoicebox(debuglevel, "300", tmpstr);
376        free(tmpstr), tmpstr = NULL;
377
378        tmpstr = ostrcat("307 - ", _("Thumbnails"), 0, 0);
379        addchoicebox(debuglevel, "307", tmpstr);
380        free(tmpstr), tmpstr = NULL;
381
382        tmpstr = ostrcat("333 - ", _("DVD Player"), 0, 0);
383        addchoicebox(debuglevel, "333", tmpstr);
384        free(tmpstr), tmpstr = NULL;
385/*
386        tmpstr = ostrcat("369 - ", _("Facebook"), 0, 0);
387        addchoicebox(debuglevel, "369", tmpstr);
388        free(tmpstr), tmpstr = NULL;
389*/
390        tmpstr = ostrcat("400 - ", _("EPG Task"), 0, 0);
391        addchoicebox(debuglevel, "400", tmpstr);
392        free(tmpstr), tmpstr = NULL;
393
394
395        tmpstr = ostrcat("401 - ", _("Old Entry"), 0, 0);
396        addchoicebox(debuglevel, "401", tmpstr);
397        free(tmpstr), tmpstr = NULL;
398
399        tmpstr = ostrcat("427 - ", _("Newsletter"), 0, 0);
400        addchoicebox(debuglevel, "427", tmpstr);
401        free(tmpstr), tmpstr = NULL;
402
403        tmpstr = ostrcat("444 - ", _("Framebuffer"), 0, 0);
404        addchoicebox(debuglevel, "444", tmpstr);
405        free(tmpstr), tmpstr = NULL;
406
407        tmpstr = ostrcat("500 - ", _("Channel Scan"), 0, 0);
408        addchoicebox(debuglevel, "500", tmpstr);
409        free(tmpstr), tmpstr = NULL;
410
411        tmpstr = ostrcat("555 - ", _("Draw Screen"), 0, 0);
412        addchoicebox(debuglevel, "555", tmpstr);
413        free(tmpstr), tmpstr = NULL;
414
415        tmpstr = ostrcat("620 - ", _("CA"), 0, 0);
416        addchoicebox(debuglevel, "620", tmpstr);
417        free(tmpstr), tmpstr = NULL;
418
419        tmpstr = ostrcat("777 - ", _("MediaDB"), 0, 0);
420        addchoicebox(debuglevel, "777", tmpstr);
421        free(tmpstr), tmpstr = NULL;
422/*
423        tmpstr = ostrcat("788 - ", _("HbbTV"), 0, 0);
424        addchoicebox(debuglevel, "788", tmpstr);
425        free(tmpstr), tmpstr = NULL;
426*/
427        tmpstr = ostrcat("900 - ", _("Mutex"), 0, 0);
428        addchoicebox(debuglevel, "900", tmpstr);
429        free(tmpstr), tmpstr = NULL;
430
431        tmpstr = ostrcat("913 - ", _("File Operation"), 0, 0);
432        addchoicebox(debuglevel, "913", tmpstr);
433        free(tmpstr), tmpstr = NULL;
434
435        tmpstr = ostrcat("975 - ", _("SMTP"), 0, 0);
436        addchoicebox(debuglevel, "975", tmpstr);
437        free(tmpstr), tmpstr = NULL;
438
439        tmpstr = ostrcat("4440 - ", _("PiP"), 0, 0);
440        addchoicebox(debuglevel, "4440", tmpstr);
441        free(tmpstr), tmpstr = NULL;
442
443        setchoiceboxselection(debuglevel, getconfig("debuglevel", NULL));
444//#endif
445
446
447#ifdef MIPSEL
448        dualboot->hidden = NO;
449        frontpoweraktion->hidden = NO;
450#else
451        dualboot->hidden = YES;
452        frontpoweraktion->hidden = YES;
453#endif
454
455        if(!file_exist("/usr/bin/enigma2"))
456                dualboot->hidden = YES;
457
458        if(status.security == 0 || checkemu() == 0)
459                emucontrol->hidden = YES;
460        else
461                emucontrol->hidden = NO;
462        if(checkbox("ATEMIO510") == 1 || checkbox("UFS912") == 1 || checkbox("UFS913") == 1 || checkbox("ATEMIO7600") == 1 || checkbox("ATEMIO520") == 1 || checkbox("ATEMIO530") == 1 || checkbox("SPARK") == 1 || checkbox("SPARK7162") == 1)
463                usecec->hidden = NO;
464        else
465                usecec->hidden = YES;
466
467        if(checkbox("ATEMIO7600") == 1)
468        {
469                sataswitch->hidden = NO;
470                addchoicebox(sataswitch, "0", _("extern"));
471                addchoicebox(sataswitch, "1", _("intern"));
472                tmpstr = getsataswitch();
473                setchoiceboxselection(sataswitch, tmpstr);
474                free(tmpstr); tmpstr = NULL;
475        }
476        else
477                sataswitch->hidden = YES;
478
479        addchoicebox(playerbuffersize, "0", _("no"));
480        addchoicebox(playerbuffersize, "524288", "512KB");
481        addchoicebox(playerbuffersize, "1048576", "1MB");
482        addchoicebox(playerbuffersize, "1572864", "1,5MB");
483        addchoicebox(playerbuffersize, "2097152", "2MB");
484        addchoicebox(playerbuffersize, "2621440", "2,5MB");
485        addchoicebox(playerbuffersize, "3145728", "3MB");
486        addchoicebox(playerbuffersize, "3670016", "3,5MB");
487        addchoicebox(playerbuffersize, "4194304", "4MB");
488        addchoicebox(playerbuffersize, "4718592", "4,5MB");
489        addchoicebox(playerbuffersize, "5242880", "5MB");
490        setchoiceboxselection(playerbuffersize, getconfig("playerbuffersize", NULL));
491
492        addchoicebox(playerbufferseektime, "0", "0");
493        addchoicebox(playerbufferseektime, "1", "1");
494        addchoicebox(playerbufferseektime, "2", "2");
495        addchoicebox(playerbufferseektime, "3", "3");
496        addchoicebox(playerbufferseektime, "4", "4");
497        addchoicebox(playerbufferseektime, "5", "5");
498        addchoicebox(playerbufferseektime, "6", "6");
499        addchoicebox(playerbufferseektime, "7", "7");
500        addchoicebox(playerbufferseektime, "8", "8");
501        addchoicebox(playerbufferseektime, "9", "9");
502        addchoicebox(playerbufferseektime, "10", "10");
503        setchoiceboxselection(playerbufferseektime, getconfig("playerbufferseektime", NULL));
504
505        drawscreen(adjust, 0, 0);
506        addscreenrc(adjust, listbox);
507
508        tmp = listbox->select;
509        while(1)
510        {
511                addscreenrc(adjust, tmp);
512                rcret = waitrc(adjust, 0, 0);
513                tmp = listbox->select;
514
515                if(rcret == getrcconfigint("rcexit", NULL)) break;
516                if(rcret == getrcconfigint("rcok", NULL))
517                {
518                        addconfigscreen("volbartimeout", volbartimeout);
519                        addconfigscreen("infobartimeout", infobartimeout);
520                        addconfigscreen("infobarsleep", infobarsleep);
521                        addconfigscreencheck("secondinfobar", secondinfobar, "0");
522                        addconfigscreen("spinnerspeed", spinnerspeed);
523                        status.spinnerspeed = getconfigint("spinnerspeed", NULL);
524                        addconfigscreen("spinnertime", spinnertime);
525                        status.spinnertime = getconfigint("spinnertime", NULL);
526                        addconfigscreen("hangtime", hangtime);
527                        status.hangtime = getconfigint("hangtime", NULL);
528                        addconfigscreencheck("nozapclear", nozapclear, "0");
529                        addconfigscreencheck("fastzap", fastzap, "0");
530                        addconfigscreencheck("faststop", faststop, "0");
531                        addconfigscreencheck("dirsort", dirsort, "0");
532                        addconfigscreencheck("poweraktion", poweraktion, "0");
533                        addconfigscreencheck("frontpoweraktion", frontpoweraktion, "0");
534                        addconfigscreencheck("recforerun", recforerun, "0");
535                        addconfigscreencheck("recoverrun", recoverrun, "0");
536                        addconfigscreencheck("virtualzap", virtualzap, "0");
537                        status.virtualzap = getconfigint("virtualzap", NULL);
538                        if(fasttextrender->ret != NULL)
539                        {
540                                addconfigscreencheck("fasttextrender", fasttextrender, "0");
541                                status.fasttextrender = atoi(fasttextrender->ret);
542                        }
543                        if(recsplitsize->ret != NULL)
544                        {
545                                addconfigscreencheck("recsplitsize", recsplitsize, "0");
546                                status.recsplitsize = atoi(recsplitsize->ret);
547                                status.recsplitsize *= 1000 * 1000 * 1000;
548                        }
549                        addconfigscreen("skip13", skip13);
550                        addconfigscreen("skip46", skip46);
551                        addconfigscreen("skip79", skip79);
552                        addconfigscreencheck("playertype", playertype, "1");
553                        addconfigscreencheck("autochangechannelname", autochangechannelname, "0");
554                        status.autochangechannelname = getconfigint("autochangechannelname", NULL);
555                        addconfigscreencheck("def_rectimer_after", def_rectimer_after, "0");
556                        addconfigscreencheck("showchanneltimeline", showchanneltimeline, "0");
557                        status.showchanneltimeline = getconfigint("showchanneltimeline", NULL);
558                        addconfigscreencheck("screenanim", screenanim, "0");
559                        status.screenanim = getconfigint("screenanim", NULL);
560                        addconfigscreencheck("screenanimspeed", screenanimspeed, "1");
561                        status.screenanimspeed = getconfigint("screenanimspeed", NULL);
562                        addconfigscreencheck("channellistview", channellistview, "0");
563                        status.channellistview = getconfigint("channellistview", NULL);
564                        addconfigscreencheck("showlastpos", showlastpos, "0");
565                        addconfigscreencheck("recsync", recsync, "0");
566                        addconfigscreencheck("recordnamefmt", recordnamefmt, "0");
567
568                        addconfigscreen("newsletter", newsletter);
569                        if(newsletter->ret != NULL && ostrcmp(newsletter->ret, "0") == 0)
570                                startnewsletter(0);
571                        else
572                                startnewsletter(1);
573
574                        addconfigscreen("showhiddenfiles", showhiddenfiles);
575                        status.showhiddenfiles = getconfigint("showhiddenfiles", NULL);
576                        addconfigscreencheck("expertmodus", expertmodus, "0");
577                        status.expertmodus = getconfigint("expertmodus", NULL);
578                        addconfigscreencheck("infobarprogram", infobarprogram, "0");
579                        status.infobarprogram = getconfigint("infobarprogram", NULL);
580                        addconfigscreen("crosscontrol", crosscontrol);
581                        //addconfigscreencheck("crosscontrol", crosscontrol, "0");
582                        status.crosscontrol = getconfigint("crosscontrol", NULL);
583                        addconfigscreencheck("emucontrol", emucontrol, "0");
584
585                        if(checkbox("ATEMIO510") == 1 || checkbox("ATEMIO520") == 1 || checkbox("ATEMIO530") == 1 || checkbox("ATEMIO7600") == 1 || checkbox("UFS912") == 1 || checkbox("UFS913") == 1 || checkbox("SPARK") == 1 || checkbox("SPARK7162") == 1)
586                                addconfigscreencheck("usecec", usecec, "0");
587
588                        if(checkbox("ATEMIO7600") == 1)
589                        {
590                                addconfigscreencheck("usecec", usecec, "0");
591                                if(sataswitch->ret != NULL)
592                                {
593                                        addownconfig("sataswitch", sataswitch->ret);
594                                        setsataswitch(sataswitch->ret);
595                                }
596                        }
597
598#ifdef MIPSEL
599                        addconfigscreen("dualboot", dualboot);
600                        if(dualboot->ret != NULL && ostrcmp(dualboot->ret, "0") == 0)
601                                unlink("/mnt/config/dualboot");
602                        else
603                                system("touch /mnt/config/dualboot");
604#endif
605
606                        addconfigscreen("zapmode", zapmode);
607                        if(zapmode->ret != NULL)
608                                setzapmode(zapmode->ret);
609
610                        addconfigscreen("playerbuffersize", playerbuffersize);
611                        addconfigscreen("playerbufferseektime", playerbufferseektime);
612
613//#ifdef BETA
614                        addconfigscreencheck("debuglevel", debuglevel, "0");
615                        setdebuglevel();
616//#endif
617                        if(community_user->ret != NULL && ostrcmp(community_user->ret, "****") != 0)
618                        {
619                                debug(99, "community_user: write");
620                                debug(99, "community_user: %s", community_user->ret);
621                                addconfigscreen("community_user", community_user);
622                        }
623                        else
624                        {
625                                debug(99, "community_user: skipped");
626                        }
627                        if(community_pass->ret != NULL && ostrcmp(community_pass->ret, "****") != 0)
628                        {
629                                debug(99, "community_pass: write");
630                                debug(99, "community_pass: %s", community_pass->ret);
631                                addconfigscreen("community_pass", community_pass);
632                        }
633                        else
634                        {
635                                debug(99, "community_pass: skipped");
636                        }
637                        writeallconfig(1);
638
639                        debug(99, "community_user read: %s", getconfig("community_user", NULL));
640                        debug(99, "community_pass read: %s", getconfig("community_pass", NULL));
641
642                        break;
643                }
644        }
645        delownerrc(adjust);
646        clearscreen(adjust);
647}
648
649#endif
Note: See TracBrowser for help on using the repository browser.